[campsite-support] Topics & Sections
  • Hi again!

    We are wondering here if we would make a section for each type of
    business branch news or making them under topics.

    Are both topics and sections limitless? Meaning that we won't put like
    100 sections or topics and then we realise that we would have needed
    101 and we can't do that... I think Campsite has these limitless
    amount but if somebody can confirm this to me, it would be nice.

    Thanks!

    Gene
  • 39 Comments sorted by
  • Hi,

    There is no limit in the number of topics or sections but with sections you
    must manage them yourself, meaning you have to be careful when numbering
    them in order to be able in the future to insert new sections in between
    older sections. Also, because of this feature you can order the sections as
    you wish but you can't do the same thing with topics.

    Sometimes it's better to have topics, sometimes it's better to have
    sections. When the number of sections is too large then maybe it's wrong to
    use sections, the publication becomes harder to maintain.

    In your case maybe it's better to build your publication the following way:
    - create a section for each business branch
    - create an article type "news"
    - create another article type that is used for more static descriptions
    (like about this section, personnel, contact etc.)

    In the section page you can display news like this:

    {{ list_articles
    constraints="type is news"
    order="byPublishDate desc" }}

    You can attach topics to each article (e.g. "graphic design" topic with the
    following subtopics: "design phase 1", "design phase 2" etc.)

    Then you can list articles both by section and topic:

    {{ list_articles
    constraints="type is news topic is design\ phase\ 1:en"
    order="byPublishDate desc" }}

    Or you can let the user select a topic from a dropdown list and set the list
    topic dynamically (see
    http://code.campware.org/manuals/campsite/3.2/index.php?id=75):

    *Note on topics*: If a certain topic was defined in the template environment
    by use of "set_topic"
    statement or URL
    parameterthe
    list will change the behavior of articles list: only articles having
    that topic will be listed.

    E.g.:

    {{ set_topic name="test:en" }}
    {{ list_articles }}
    ...
    {{ /list_articles }}

    There's also an advanced search feature:
    http://code.campware.org/manuals/campsite/3.2/index.php?id=300

    Hope this helps,
    Mugur

    On Mon, Jun 8, 2009 at 1:47 PM, Generare Management Department <
    management@generare.com> wrote:

    > Hi again!
    >
    > We are wondering here if we would make a section for each type of business
    > branch news or making them under topics.
    >
    > Are both topics and sections limitless? Meaning that we won't put like 100
    > sections or topics and then we realise that we would have needed 101 and we
    > can't do that... I think Campsite has these limitless amount but if somebody
    > can confirm this to me, it would be nice.
    >
    > Thanks!
    >
    > Gene
    >
  • Thanks a lot Mugur for your great, explanative email!

    Is there a way to have identical duplicates of the same article under
    two different sections?
    Meaning also that if you edit the first one, also the other one will
    change automatically. I did find the command "duplicate" but that
    seems to make a completely new news article using the data of the
    older one as basis.

    Often you see for example a celebrity campaining for environment
    issues. Then this article would belong under the Entertainment section
    but also under the Environment section.

    We calculated that our final amount of business branches (sections or
    topics) would be around 20 different ones.

    Gene

    On 9.6.2009, at 14.08, Mugur Rus wrote:

    > Hi,
    >
    > There is no limit in the number of topics or sections but with
    > sections you must manage them yourself, meaning you have to be
    > careful when numbering them in order to be able in the future to
    > insert new sections in between older sections. Also, because of this
    > feature you can order the sections as you wish but you can't do the
    > same thing with topics.
    >
    > Sometimes it's better to have topics, sometimes it's better to have
    > sections. When the number of sections is too large then maybe it's
    > wrong to use sections, the publication becomes harder to maintain.
    >
    > In your case maybe it's better to build your publication the
    > following way:
    > - create a section for each business branch
    > - create an article type "news"
    > - create another article type that is used for more static
    > descriptions (like about this section, personnel, contact etc.)
    >
    > In the section page you can display news like this:
    >
    > {{ list_articles
    > constraints="type is news"
    > order="byPublishDate desc" }}
    >
    > You can attach topics to each article (e.g. "graphic design" topic
    > with the following subtopics: "design phase 1", "design phase 2" etc.)
    >
    > Then you can list articles both by section and topic:
    >
    > {{ list_articles
    > constraints="type is news topic is design\ phase\ 1:en"
    > order="byPublishDate desc" }}
    >
    > Or you can let the user select a topic from a dropdown list and set
    > the list topic dynamically (see http://code.campware.org/manuals/campsite/3.2/index.php?id=75)
    > :
    > Note on topics: If a certain topic was defined in the template
    > environment by use of "set_topic" statement or URL parameter the
    > list will change the behavior of articles list: only articles having
    > that topic will be listed.
    > E.g.:
    >
    > {{ set_topic name="test:en" }}
    > {{ list_articles }}
    > ...
    > {{ /list_articles }}
    > There's also an advanced search feature: http://code.campware.org/manuals/campsite/3.2/index.php?id=300
    >
    > Hope this helps,
    > Mugur
    >
    > On Mon, Jun 8, 2009 at 1:47 PM, Generare Management Department > > wrote:
    > Hi again!
    >
    > We are wondering here if we would make a section for each type of
    > business branch news or making them under topics.
    >
    > Are both topics and sections limitless? Meaning that we won't put
    > like 100 sections or topics and then we realise that we would have
    > needed 101 and we can't do that... I think Campsite has these
    > limitless amount but if somebody can confirm this to me, it would be
    > nice.
    >
    > Thanks!
    >
    > Gene
    >
  • Hi Gene,

    In this case it's better to use topics as there is no way in campsite to
    make an article belong to multiple sections. But with topics you can attach
    as many topics as you want to an article. So your article will show up in
    both the list of articles having the topic Entertainment and the list of
    articles having the topic Environment.

    Mugur

    On Wed, Jun 10, 2009 at 11:55 AM, Generare Management Department <
    management@generare.com> wrote:

    > Thanks a lot Mugur for your great, explanative email!
    > Is there a way to have identical duplicates of the same article under two
    > different sections?
    > Meaning also that if you edit the first one, also the other one will change
    > automatically. I did find the command "duplicate" but that seems to make a
    > completely new news article using the data of the older one as basis.
    >
    > Often you see for example a celebrity campaining for environment issues.
    > Then this article would belong under the Entertainment section but also
    > under the Environment section.
    >
    > We calculated that our final amount of business branches (sections or
    > topics) would be around 20 different ones.
    >
    > Gene
    >
    > On 9.6.2009, at 14.08, Mugur Rus wrote:
    >
    > Hi,
    >
    > There is no limit in the number of topics or sections but with sections you
    > must manage them yourself, meaning you have to be careful when numbering
    > them in order to be able in the future to insert new sections in between
    > older sections. Also, because of this feature you can order the sections as
    > you wish but you can't do the same thing with topics.
    >
    > Sometimes it's better to have topics, sometimes it's better to have
    > sections. When the number of sections is too large then maybe it's wrong to
    > use sections, the publication becomes harder to maintain.
    >
    > In your case maybe it's better to build your publication the following way:
    > - create a section for each business branch
    > - create an article type "news"
    > - create another article type that is used for more static descriptions
    > (like about this section, personnel, contact etc.)
    >
    > In the section page you can display news like this:
    >
    > {{ list_articles
    > constraints="type is news"
    > order="byPublishDate desc" }}
    >
    > You can attach topics to each article (e.g. "graphic design" topic with the
    > following subtopics: "design phase 1", "design phase 2" etc.)
    >
    > Then you can list articles both by section and topic:
    >
    > {{ list_articles
    > constraints="type is news topic is design\ phase\ 1:en"
    > order="byPublishDate desc" }}
    >
    > Or you can let the user select a topic from a dropdown list and set the
    > list topic dynamically (see
    > http://code.campware.org/manuals/campsite/3.2/index.php?id=75):
    >
    > *Note on topics*: If a certain topic was defined in the template
    > environment by use of "set_topic"
    > statement or URL parameterthe list will change the behavior of articles list: only articles having
    > that topic will be listed.
    >
    > E.g.:
    >
    > {{ set_topic name="test:en" }}
    > {{ list_articles }}
    > ...
    > {{ /list_articles }}
    >
    > There's also an advanced search feature:
    > http://code.campware.org/manuals/campsite/3.2/index.php?id=300
    >
    > Hope this helps,
    > Mugur
    >
    > On Mon, Jun 8, 2009 at 1:47 PM, Generare Management Department <
    > management@generare.com> wrote:
    >
    >> Hi again!
    >>
    >> We are wondering here if we would make a section for each type of business
    >> branch news or making them under topics.
    >>
    >> Are both topics and sections limitless? Meaning that we won't put like 100
    >> sections or topics and then we realise that we would have needed 101 and we
    >> can't do that... I think Campsite has these limitless amount but if somebody
    >> can confirm this to me, it would be nice.
    >>
    >> Thanks!
    >>
    >> Gene
    >>
    >
    >
    >
    >
    >
    >
  • Ok, I looked the Topics to add some new ones but the whole admin gets
    blank when I go to Configure -> Topics.
    I was able to go there before, atleast before the last upgrade. This
    is Campsite 3.2.3 "David".

    Anybody else experiencing issues with Topics?

    G

    On 10.6.2009, at 12.36, Mugur Rus wrote:

    > Hi Gene,
    >
    > In this case it's better to use topics as there is no way in
    > campsite to make an article belong to multiple sections. But with
    > topics you can attach as many topics as you want to an article. So
    > your article will show up in both the list of articles having the
    > topic Entertainment and the list of articles having the topic
    > Environment.
    >
    > Mugur
    >
    > On Wed, Jun 10, 2009 at 11:55 AM, Generare Management Department > > wrote:
    > Thanks a lot Mugur for your great, explanative email!
    >
    > Is there a way to have identical duplicates of the same article
    > under two different sections?
    > Meaning also that if you edit the first one, also the other one will
    > change automatically. I did find the command "duplicate" but that
    > seems to make a completely new news article using the data of the
    > older one as basis.
    >
    > Often you see for example a celebrity campaining for environment
    > issues. Then this article would belong under the Entertainment
    > section but also under the Environment section.
    >
    > We calculated that our final amount of business branches (sections
    > or topics) would be around 20 different ones.
    >
    > Gene
    >
    > On 9.6.2009, at 14.08, Mugur Rus wrote:
    >
    >> Hi,
    >>
    >> There is no limit in the number of topics or sections but with
    >> sections you must manage them yourself, meaning you have to be
    >> careful when numbering them in order to be able in the future to
    >> insert new sections in between older sections. Also, because of
    >> this feature you can order the sections as you wish but you can't
    >> do the same thing with topics.
    >>
    >> Sometimes it's better to have topics, sometimes it's better to have
    >> sections. When the number of sections is too large then maybe it's
    >> wrong to use sections, the publication becomes harder to maintain.
    >>
    >> In your case maybe it's better to build your publication the
    >> following way:
    >> - create a section for each business branch
    >> - create an article type "news"
    >> - create another article type that is used for more static
    >> descriptions (like about this section, personnel, contact etc.)
    >>
    >> In the section page you can display news like this:
    >>
    >> {{ list_articles
    >> constraints="type is news"
    >> order="byPublishDate desc" }}
    >>
    >> You can attach topics to each article (e.g. "graphic design" topic
    >> with the following subtopics: "design phase 1", "design phase 2"
    >> etc.)
    >>
    >> Then you can list articles both by section and topic:
    >>
    >> {{ list_articles
    >> constraints="type is news topic is design\ phase\ 1:en"
    >> order="byPublishDate desc" }}
    >>
    >> Or you can let the user select a topic from a dropdown list and set
    >> the list topic dynamically (see http://code.campware.org/manuals/campsite/3.2/index.php?id=75)
    >> :
    >> Note on topics: If a certain topic was defined in the template
    >> environment by use of "set_topic" statement or URL parameter the
    >> list will change the behavior of articles list: only articles
    >> having that topic will be listed.
    >> E.g.:
    >>
    >> {{ set_topic name="test:en" }}
    >> {{ list_articles }}
    >> ...
    >> {{ /list_articles }}
    >> There's also an advanced search feature: http://code.campware.org/manuals/campsite/3.2/index.php?id=300
    >>
    >> Hope this helps,
    >> Mugur
    >>
    >> On Mon, Jun 8, 2009 at 1:47 PM, Generare Management Department >> > wrote:
    >> Hi again!
    >>
    >> We are wondering here if we would make a section for each type of
    >> business branch news or making them under topics.
    >>
    >> Are both topics and sections limitless? Meaning that we won't put
    >> like 100 sections or topics and then we realise that we would have
    >> needed 101 and we can't do that... I think Campsite has these
    >> limitless amount but if somebody can confirm this to me, it would
    >> be nice.
    >>
    >> Thanks!
    >>
    >> Gene
    >>
    >
    >
  • Hi Gene,

    Just checked all my Campsite installations and I detected no problems with
    topics.

    Just to add to what Mugur said, in your case, think of Sections as of wider
    categories to organize and manage content (primarily in the backend). It
    seems to me Topics (which is just our legacy name for tags) would be
    perfectly suited for your purposes (including showing the same article
    multiple times, in different contexts). A good example of the power of
    topics is http://www.tol.org Although the site is old, this is perhaps the
    best example of this flexible approach (for example, all articles are
    featured in Country Reports as well as in their regular section).

    All the best,

    Sava



    |------------>
    | From: |
    |------------>
    >--------------------------------------------------------------------------------------------------------------------------------------------------|
    |Generare Management Department |
    >--------------------------------------------------------------------------------------------------------------------------------------------------|
    |------------>
    | To: |
    |------------>
    >--------------------------------------------------------------------------------------------------------------------------------------------------|
    |campsite-support@campware.org |
    >--------------------------------------------------------------------------------------------------------------------------------------------------|
    |------------>
    | Date: |
    |------------>
    >--------------------------------------------------------------------------------------------------------------------------------------------------|
    |06/10/2009 12:20 PM |
    >--------------------------------------------------------------------------------------------------------------------------------------------------|
    |------------>
    | Subject: |
    |------------>
    >--------------------------------------------------------------------------------------------------------------------------------------------------|
    |Re: [campsite-support] Topics & Sections |
    >--------------------------------------------------------------------------------------------------------------------------------------------------|





    Ok, I looked the Topics to add some new ones but the whole admin gets blank
    when I go to Configure -> Topics.
    I was able to go there before, atleast before the last upgrade. This is
    Campsite 3.2.3 "David".

    Anybody else experiencing issues with Topics?

    G

    On 10.6.2009, at 12.36, Mugur Rus wrote:

    Hi Gene,

    In this case it's better to use topics as there is no way in campsite
    to make an article belong to multiple sections. But with topics you
    can attach as many topics as you want to an article. So your article
    will show up in both the list of articles having the topic
    Entertainment and the list of articles having the topic Environment.

    Mugur

    On Wed, Jun 10, 2009 at 11:55 AM, Generare Management Department <
    management@generare.com> wrote:
    Thanks a lot Mugur for your great, explanative email!

    Is there a way to have identical duplicates of the same article
    under two different sections?
    Meaning also that if you edit the first one, also the other one
    will change automatically. I did find the command "duplicate" but
    that seems to make a completely new news article using the data of
    the older one as basis.

    Often you see for example a celebrity campaining for environment
    issues. Then this article would belong under the Entertainment
    section but also under the Environment section.

    We calculated that our final amount of business branches (sections
    or topics) would be around 20 different ones.

    Gene

    On 9.6.2009, at 14.08, Mugur Rus wrote:

    Hi,

    There is no limit in the number of topics or sections but
    with sections you must manage them yourself, meaning you have
    to be careful when numbering them in order to be able in the
    future to insert new sections in between older sections.
    Also, because of this feature you can order the sections as
    you wish but you can't do the same thing with topics.

    Sometimes it's better to have topics, sometimes it's better
    to have sections. When the number of sections is too large
    then maybe it's wrong to use sections, the publication
    becomes harder to maintain.

    In your case maybe it's better to build your publication the
    following way:
    - create a section for each business branch
    - create an article type "news"
    - create another article type that is used for more static
    descriptions (like about this section, personnel, contact
    etc.)

    In the section page you can display news like this:

    {{ list_articles
    constraints="type is news"
    order="byPublishDate desc" }}

    You can attach topics to each article (e.g. "graphic design"
    topic with the following subtopics: "design phase 1", "design
    phase 2" etc.)

    Then you can list articles both by section and topic:

    {{ list_articles
    constraints="type is news topic is design\ phase\ 1:en"
    order="byPublishDate desc" }}

    Or you can let the user select a topic from a dropdown list
    and set the list topic dynamically (see
    http://code.campware.org/manuals/campsite/3.2/index.php?id=75
    ):


    Note on topics: If a certain topic was defined in the
    template environment by use of "set_topic" statement or URL
    parameter the list will change the behavior of articles list:
    only articles having that topic will be listed.


    E.g.:


    {{ set_topic name="test:en" }}
    {{ list_articles }}
    ...
    {{ /list_articles }}
    There's also an advanced search feature:
    http://code.campware.org/manuals/campsite/3.2/index.php?id=300


    Hope this helps,
    Mugur

    On Mon, Jun 8, 2009 at 1:47 PM, Generare Management
    Department wrote:
    Hi again!

    We are wondering here if we would make a section for each
    type of business branch news or making them under topics.

    Are both topics and sections limitless? Meaning that we
    won't put like 100 sections or topics and then we realise
    that we would have needed 101 and we can't do that... I
    think Campsite has these limitless amount but if somebody
    can confirm this to me, it would be nice.

    Thanks!

    Gene
  • Hi,

    and thanks very much for the comments and help.
    I will try to upload some files again into the server and look if the
    Topics is accessible in admin again then.
    I haven't changed there anything else than the languages
    add_modify.php that Mugur gave. I doubt that file effects on Topics
    anyhow.

    That TOL example is great, no matter if the site is old already. Would
    you have some examples how the templates for the navigation and drop-
    down has been built? Basicly need to just add the proper topics and
    some sections and of course to link the articles for the topics as
    well. We always tumble here when we need to understand how the link in
    the template really is built!

    /G

    On 10.6.2009, at 14.49, sava.tatic@mdlf.org wrote:

    > Hi Gene,
    >
    > Just checked all my Campsite installations and I detected no
    > problems with
    > topics.
    >
    > Just to add to what Mugur said, in your case, think of Sections as
    > of wider
    > categories to organize and manage content (primarily in the
    > backend). It
    > seems to me Topics (which is just our legacy name for tags) would be
    > perfectly suited for your purposes (including showing the same article
    > multiple times, in different contexts). A good example of the power of
    > topics is http://www.tol.org Although the site is old, this is
    > perhaps the
    > best example of this flexible approach (for example, all articles are
    > featured in Country Reports as well as in their regular section).
    >
    > All the best,
    >
    > Sava
    >
    >
    >
    > |------------>
    > | From: |
    > |------------>
    >> --------------------------------------------------------------------------------------------------------------------------------------------------|
    > |Generare Management Department
    > <
    > management
    > @generare
    > .com
    > >
    > |
    >> --------------------------------------------------------------------------------------------------------------------------------------------------|
    > |------------>
    > | To: |
    > |------------>
    >> --------------------------------------------------------------------------------------------------------------------------------------------------|
    > |campsite-
    > support
    > @campware
    > .org
    > |
    >> --------------------------------------------------------------------------------------------------------------------------------------------------|
    > |------------>
    > | Date: |
    > |------------>
    >> --------------------------------------------------------------------------------------------------------------------------------------------------|
    > |06/10/2009 12:20
    > PM
    > |
    >> --------------------------------------------------------------------------------------------------------------------------------------------------|
    > |------------>
    > | Subject: |
    > |------------>
    >> --------------------------------------------------------------------------------------------------------------------------------------------------|
    > |Re: [campsite-support] Topics &
    > Sections
    > |
    >> --------------------------------------------------------------------------------------------------------------------------------------------------|
    >
    >
    >
    >
    >
    > Ok, I looked the Topics to add some new ones but the whole admin
    > gets blank
    > when I go to Configure -> Topics.
    > I was able to go there before, atleast before the last upgrade. This
    > is
    > Campsite 3.2.3 "David".
    >
    > Anybody else experiencing issues with Topics?
    >
    > G
    >
    > On 10.6.2009, at 12.36, Mugur Rus wrote:
    >
    > Hi Gene,
    >
    > In this case it's better to use topics as there is no way in
    > campsite
    > to make an article belong to multiple sections. But with topics
    > you
    > can attach as many topics as you want to an article. So your
    > article
    > will show up in both the list of articles having the topic
    > Entertainment and the list of articles having the topic
    > Environment.
    >
    > Mugur
    >
    > On Wed, Jun 10, 2009 at 11:55 AM, Generare Management
    > Department <
    > management@generare.com> wrote:
    > Thanks a lot Mugur for your great, explanative email!
    >
    > Is there a way to have identical duplicates of the same article
    > under two different sections?
    > Meaning also that if you edit the first one, also the other one
    > will change automatically. I did find the command "duplicate"
    > but
    > that seems to make a completely new news article using the
    > data of
    > the older one as basis.
    >
    > Often you see for example a celebrity campaining for
    > environment
    > issues. Then this article would belong under the Entertainment
    > section but also under the Environment section.
    >
    > We calculated that our final amount of business branches
    > (sections
    > or topics) would be around 20 different ones.
    >
    > Gene
    >
    > On 9.6.2009, at 14.08, Mugur Rus wrote:
    >
    > Hi,
    >
    > There is no limit in the number of topics or sections but
    > with sections you must manage them yourself, meaning
    > you have
    > to be careful when numbering them in order to be able
    > in the
    > future to insert new sections in between older sections.
    > Also, because of this feature you can order the
    > sections as
    > you wish but you can't do the same thing with topics.
    >
    > Sometimes it's better to have topics, sometimes it's
    > better
    > to have sections. When the number of sections is too
    > large
    > then maybe it's wrong to use sections, the publication
    > becomes harder to maintain.
    >
    > In your case maybe it's better to build your
    > publication the
    > following way:
    > - create a section for each business branch
    > - create an article type "news"
    > - create another article type that is used for more
    > static
    > descriptions (like about this section, personnel, contact
    > etc.)
    >
    > In the section page you can display news like this:
    >
    > {{ list_articles
    > constraints="type is news"
    > order="byPublishDate desc" }}
    >
    > You can attach topics to each article (e.g. "graphic
    > design"
    > topic with the following subtopics: "design phase 1",
    > "design
    > phase 2" etc.)
    >
    > Then you can list articles both by section and topic:
    >
    > {{ list_articles
    > constraints="type is news topic is design\ phase\
    > 1:en"
    > order="byPublishDate desc" }}
    >
    > Or you can let the user select a topic from a dropdown
    > list
    > and set the list topic dynamically (see
    > http://code.campware.org/manuals/campsite/3.2/index.php?id=75
    > ):
    >
    >
    > Note on topics: If a certain topic was defined in the
    > template environment by use of "set_topic" statement or
    > URL
    > parameter the list will change the behavior of articles
    > list:
    > only articles having that topic will be listed.
    >
    >
    > E.g.:
    >
    >
    > {{ set_topic name="test:en" }}
    > {{ list_articles }}
    > ...
    > {{ /list_articles }}
    > There's also an advanced search feature:
    > http://code.campware.org/manuals/campsite/3.2/index.php?id=300
    >
    >
    > Hope this helps,
    > Mugur
    >
    > On Mon, Jun 8, 2009 at 1:47 PM, Generare Management
    > Department wrote:
    > Hi again!
    >
    > We are wondering here if we would make a section for
    > each
    > type of business branch news or making them under
    > topics.
    >
    > Are both topics and sections limitless? Meaning that we
    > won't put like 100 sections or topics and then we
    > realise
    > that we would have needed 101 and we can't do that... I
    > think Campsite has these limitless amount but if
    > somebody
    > can confirm this to me, it would be nice.
    >
    > Thanks!
    >
    > Gene
    >
  • Please try to load the topics page again and then take a look at the apache
    error log, see if you get a hint from there.

    Mugur

    On Wed, Jun 10, 2009 at 1:19 PM, Generare Management Department <
    management@generare.com> wrote:

    > Ok, I looked the Topics to add some new ones but the whole admin gets blank
    > when I go to Configure -> Topics.I was able to go there before, atleast
    > before the last upgrade. This is Campsite 3.2.3 "David".
    >
    > Anybody else experiencing issues with Topics?
    >
    > G
    >
    > On 10.6.2009, at 12.36, Mugur Rus wrote:
    >
    > Hi Gene,
    >
    > In this case it's better to use topics as there is no way in campsite to
    > make an article belong to multiple sections. But with topics you can attach
    > as many topics as you want to an article. So your article will show up in
    > both the list of articles having the topic Entertainment and the list of
    > articles having the topic Environment.
    >
    > Mugur
    >
    > On Wed, Jun 10, 2009 at 11:55 AM, Generare Management Department <
    > management@generare.com> wrote:
    >
    >> Thanks a lot Mugur for your great, explanative email!
    >> Is there a way to have identical duplicates of the same article under two
    >> different sections?
    >> Meaning also that if you edit the first one, also the other one will
    >> change automatically. I did find the command "duplicate" but that seems to
    >> make a completely new news article using the data of the older one as basis.
    >>
    >> Often you see for example a celebrity campaining for environment issues.
    >> Then this article would belong under the Entertainment section but also
    >> under the Environment section.
    >>
    >> We calculated that our final amount of business branches (sections or
    >> topics) would be around 20 different ones.
    >>
    >> Gene
    >>
    >> On 9.6.2009, at 14.08, Mugur Rus wrote:
    >>
    >> Hi,
    >>
    >> There is no limit in the number of topics or sections but with sections
    >> you must manage them yourself, meaning you have to be careful when numbering
    >> them in order to be able in the future to insert new sections in between
    >> older sections. Also, because of this feature you can order the sections as
    >> you wish but you can't do the same thing with topics.
    >>
    >> Sometimes it's better to have topics, sometimes it's better to have
    >> sections. When the number of sections is too large then maybe it's wrong to
    >> use sections, the publication becomes harder to maintain.
    >>
    >> In your case maybe it's better to build your publication the following
    >> way:
    >> - create a section for each business branch
    >> - create an article type "news"
    >> - create another article type that is used for more static descriptions
    >> (like about this section, personnel, contact etc.)
    >>
    >> In the section page you can display news like this:
    >>
    >> {{ list_articles
    >> constraints="type is news"
    >> order="byPublishDate desc" }}
    >>
    >> You can attach topics to each article (e.g. "graphic design" topic with
    >> the following subtopics: "design phase 1", "design phase 2" etc.)
    >>
    >> Then you can list articles both by section and topic:
    >>
    >> {{ list_articles
    >> constraints="type is news topic is design\ phase\ 1:en"
    >> order="byPublishDate desc" }}
    >>
    >> Or you can let the user select a topic from a dropdown list and set the
    >> list topic dynamically (see
    >> http://code.campware.org/manuals/campsite/3.2/index.php?id=75):
    >>
    >> *Note on topics*: If a certain topic was defined in the template
    >> environment by use of "set_topic"
    >> statement or URL parameterthe list will change the behavior of articles list: only articles having
    >> that topic will be listed.
    >>
    >> E.g.:
    >>
    >> {{ set_topic name="test:en" }}
    >> {{ list_articles }}
    >> ...
    >> {{ /list_articles }}
    >>
    >> There's also an advanced search feature:
    >> http://code.campware.org/manuals/campsite/3.2/index.php?id=300
    >>
    >> Hope this helps,
    >> Mugur
    >>
    >> On Mon, Jun 8, 2009 at 1:47 PM, Generare Management Department <
    >> management@generare.com> wrote:
    >>
    >>> Hi again!
    >>>
    >>> We are wondering here if we would make a section for each type of
    >>> business branch news or making them under topics.
    >>>
    >>> Are both topics and sections limitless? Meaning that we won't put like
    >>> 100 sections or topics and then we realise that we would have needed 101 and
    >>> we can't do that... I think Campsite has these limitless amount but if
    >>> somebody can confirm this to me, it would be nice.
    >>>
    >>> Thanks!
    >>>
    >>> Gene
    >>>
    >>
    >>
    >>
    >
    >
    >
  • Yes, I loaded the topics admin files again, no change.

    But I did get it solved and I just needed to logout and then login
    again that the English languade id changed from "en" to "en_US" that I
    had changed it in Languages earlier.

    If it helps somebody else, the error was:

    [Thu Jun 11 15:10:16 2009] [error] [client xx.xx.xxx.xx] PHP Fatal
    error: Call to a member function getLanguageId() on a non-object in /
    home/webadmin/www.mydomaininfo.here/html/admin-files/topics/index.php
    on line 14,...

    /G

    On 10.6.2009, at 17.44, Mugur Rus wrote:

    > Please try to load the topics page again and then take a look at the
    > apache error log, see if you get a hint from there.
    >
    > Mugur
    >
    > On Wed, Jun 10, 2009 at 1:19 PM, Generare Management Department > > wrote:
    > Ok, I looked the Topics to add some new ones but the whole admin
    > gets blank when I go to Configure -> Topics.
    > I was able to go there before, atleast before the last upgrade. This
    > is Campsite 3.2.3 "David".
    >
    > Anybody else experiencing issues with Topics?
    >
    > G
    >
    > On 10.6.2009, at 12.36, Mugur Rus wrote:
    >
    >> Hi Gene,
    >>
    >> In this case it's better to use topics as there is no way in
    >> campsite to make an article belong to multiple sections. But with
    >> topics you can attach as many topics as you want to an article. So
    >> your article will show up in both the list of articles having the
    >> topic Entertainment and the list of articles having the topic
    >> Environment.
    >>
    >> Mugur
    >>
    >> On Wed, Jun 10, 2009 at 11:55 AM, Generare Management Department >> > wrote:
    >> Thanks a lot Mugur for your great, explanative email!
    >>
    >> Is there a way to have identical duplicates of the same article
    >> under two different sections?
    >> Meaning also that if you edit the first one, also the other one
    >> will change automatically. I did find the command "duplicate" but
    >> that seems to make a completely new news article using the data of
    >> the older one as basis.
    >>
    >> Often you see for example a celebrity campaining for environment
    >> issues. Then this article would belong under the Entertainment
    >> section but also under the Environment section.
    >>
    >> We calculated that our final amount of business branches (sections
    >> or topics) would be around 20 different ones.
    >>
    >> Gene
    >>
    >> On 9.6.2009, at 14.08, Mugur Rus wrote:
    >>
    >>> Hi,
    >>>
    >>> There is no limit in the number of topics or sections but with
    >>> sections you must manage them yourself, meaning you have to be
    >>> careful when numbering them in order to be able in the future to
    >>> insert new sections in between older sections. Also, because of
    >>> this feature you can order the sections as you wish but you can't
    >>> do the same thing with topics.
    >>>
    >>> Sometimes it's better to have topics, sometimes it's better to
    >>> have sections. When the number of sections is too large then maybe
    >>> it's wrong to use sections, the publication becomes harder to
    >>> maintain.
    >>>
    >>> In your case maybe it's better to build your publication the
    >>> following way:
    >>> - create a section for each business branch
    >>> - create an article type "news"
    >>> - create another article type that is used for more static
    >>> descriptions (like about this section, personnel, contact etc.)
    >>>
    >>> In the section page you can display news like this:
    >>>
    >>> {{ list_articles
    >>> constraints="type is news"
    >>> order="byPublishDate desc" }}
    >>>
    >>> You can attach topics to each article (e.g. "graphic design" topic
    >>> with the following subtopics: "design phase 1", "design phase 2"
    >>> etc.)
    >>>
    >>> Then you can list articles both by section and topic:
    >>>
    >>> {{ list_articles
    >>> constraints="type is news topic is design\ phase\ 1:en"
    >>> order="byPublishDate desc" }}
    >>>
    >>> Or you can let the user select a topic from a dropdown list and
    >>> set the list topic dynamically (see http://code.campware.org/manuals/campsite/3.2/index.php?id=75)
    >>> :
    >>> Note on topics: If a certain topic was defined in the template
    >>> environment by use of "set_topic" statement or URL parameter the
    >>> list will change the behavior of articles list: only articles
    >>> having that topic will be listed.
    >>> E.g.:
    >>>
    >>> {{ set_topic name="test:en" }}
    >>> {{ list_articles }}
    >>> ...
    >>> {{ /list_articles }}
    >>> There's also an advanced search feature: http://code.campware.org/manuals/campsite/3.2/index.php?id=300
    >>>
    >>> Hope this helps,
    >>> Mugur
    >>>
    >>> On Mon, Jun 8, 2009 at 1:47 PM, Generare Management Department >>> > wrote:
    >>> Hi again!
    >>>
    >>> We are wondering here if we would make a section for each type of
    >>> business branch news or making them under topics.
    >>>
    >>> Are both topics and sections limitless? Meaning that we won't put
    >>> like 100 sections or topics and then we realise that we would have
    >>> needed 101 and we can't do that... I think Campsite has these
    >>> limitless amount but if somebody can confirm this to me, it would
    >>> be nice.
    >>>
    >>> Thanks!
    >>>
    >>> Gene
    >>>
    >>
    >>
  • Hi!

    Here we are finetuning the content and the huge amount of languages.
    Some languages are appearing only with few articles, some are more
    common.

    We would like to have the English front page having mixed fresh
    releases of articles.
    It is not a problem to do so or look like we understood how to build
    it but now we get also the same mixed idea if we click on other
    languages front page. How do I restrict the mixed, fresh releases to
    appear only with English and the other languages would be pure, only
    that language translations that is selected to as viewed?

    I hope you can understand what is the idea.

    Gene
  • Thanks, fixed this issue.

    Mugur

    On Thu, Jun 11, 2009 at 4:12 PM, Generare Management Department <
    management@generare.com> wrote:

    > Yes, I loaded the topics admin files again, no change.
    > But I did get it solved and I just needed to logout and then login again
    > that the English languade id changed from "en" to "en_US" that I had changed
    > it in Languages earlier.
    >
    > If it helps somebody else, the error was:
    >
    > [Thu Jun 11 15:10:16 2009] [error] [client xx.xx.xxx.xx] PHP Fatal error:
    > Call to a member function getLanguageId() on a non-object in
    > /home/webadmin/www.mydomaininfo.here/html/admin-files/topics/index.php on
    > line 14,...
    >
    > /G
    >
    > On 10.6.2009, at 17.44, Mugur Rus wrote:
    >
    > Please try to load the topics page again and then take a look at the apache
    > error log, see if you get a hint from there.
    >
    > Mugur
    >
    > On Wed, Jun 10, 2009 at 1:19 PM, Generare Management Department <
    > management@generare.com> wrote:
    >
    >> Ok, I looked the Topics to add some new ones but the whole admin gets
    >> blank when I go to Configure -> Topics. I was able to go there before,
    >> atleast before the last upgrade. This is Campsite 3.2.3 "David".
    >>
    >> Anybody else experiencing issues with Topics?
    >>
    >> G
    >>
    >> On 10.6.2009, at 12.36, Mugur Rus wrote:
    >>
    >> Hi Gene,
    >>
    >> In this case it's better to use topics as there is no way in campsite to
    >> make an article belong to multiple sections. But with topics you can attach
    >> as many topics as you want to an article. So your article will show up in
    >> both the list of articles having the topic Entertainment and the list of
    >> articles having the topic Environment.
    >>
    >> Mugur
    >>
    >> On Wed, Jun 10, 2009 at 11:55 AM, Generare Management Department <
    >> management@generare.com> wrote:
    >>
    >>> Thanks a lot Mugur for your great, explanative email!
    >>> Is there a way to have identical duplicates of the same article under two
    >>> different sections?
    >>> Meaning also that if you edit the first one, also the other one will
    >>> change automatically. I did find the command "duplicate" but that seems to
    >>> make a completely new news article using the data of the older one as basis.
    >>>
    >>> Often you see for example a celebrity campaining for environment issues.
    >>> Then this article would belong under the Entertainment section but also
    >>> under the Environment section.
    >>>
    >>> We calculated that our final amount of business branches (sections or
    >>> topics) would be around 20 different ones.
    >>>
    >>> Gene
    >>>
    >>> On 9.6.2009, at 14.08, Mugur Rus wrote:
    >>>
    >>> Hi,
    >>>
    >>> There is no limit in the number of topics or sections but with sections
    >>> you must manage them yourself, meaning you have to be careful when numbering
    >>> them in order to be able in the future to insert new sections in between
    >>> older sections. Also, because of this feature you can order the sections as
    >>> you wish but you can't do the same thing with topics.
    >>>
    >>> Sometimes it's better to have topics, sometimes it's better to have
    >>> sections. When the number of sections is too large then maybe it's wrong to
    >>> use sections, the publication becomes harder to maintain.
    >>>
    >>> In your case maybe it's better to build your publication the following
    >>> way:
    >>> - create a section for each business branch
    >>> - create an article type "news"
    >>> - create another article type that is used for more static descriptions
    >>> (like about this section, personnel, contact etc.)
    >>>
    >>> In the section page you can display news like this:
    >>>
    >>> {{ list_articles
    >>> constraints="type is news"
    >>> order="byPublishDate desc" }}
    >>>
    >>> You can attach topics to each article (e.g. "graphic design" topic with
    >>> the following subtopics: "design phase 1", "design phase 2" etc.)
    >>>
    >>> Then you can list articles both by section and topic:
    >>>
    >>> {{ list_articles
    >>> constraints="type is news topic is design\ phase\ 1:en"
    >>> order="byPublishDate desc" }}
    >>>
    >>> Or you can let the user select a topic from a dropdown list and set the
    >>> list topic dynamically (see
    >>> http://code.campware.org/manuals/campsite/3.2/index.php?id=75):
    >>>
    >>> *Note on topics*: If a certain topic was defined in the template
    >>> environment by use of "set_topic"
    >>> statement or URL parameterthe list will change the behavior of articles list: only articles having
    >>> that topic will be listed.
    >>>
    >>> E.g.:
    >>>
    >>> {{ set_topic name="test:en" }}
    >>> {{ list_articles }}
    >>> ...
    >>> {{ /list_articles }}
    >>>
    >>> There's also an advanced search feature:
    >>> http://code.campware.org/manuals/campsite/3.2/index.php?id=300
    >>>
    >>> Hope this helps,
    >>> Mugur
    >>>
    >>> On Mon, Jun 8, 2009 at 1:47 PM, Generare Management Department <
    >>> management@generare.com> wrote:
    >>>
    >>>> Hi again!
    >>>>
    >>>> We are wondering here if we would make a section for each type of
    >>>> business branch news or making them under topics.
    >>>>
    >>>> Are both topics and sections limitless? Meaning that we won't put like
    >>>> 100 sections or topics and then we realise that we would have needed 101 and
    >>>> we can't do that... I think Campsite has these limitless amount but if
    >>>> somebody can confirm this to me, it would be nice.
    >>>>
    >>>> Thanks!
    >>>>
    >>>> Gene
    >>>>
    >>>
    >>>
    >>>
    >
    >
    >
  • Use the language data to decide how do you display the articles:

    {{ if $campsite->language->code = "en" }}
    {{ assign var="ignore_language" value="true" }}
    {{ else }}
    {{ assign var="ignore_language" value="false" }}
    {{ /if }}
    {{ list_articles ignore_language=`$ignore_language` }}

    Hope this helps,
    Mugur

    On Mon, Jun 15, 2009 at 10:13 PM, Generare Management Department <
    management@generare.com> wrote:

    > Hi!
    >
    > Here we are finetuning the content and the huge amount of languages.
    > Some languages are appearing only with few articles, some are more common.
    >
    > We would like to have the English front page having mixed fresh releases of
    > articles.
    > It is not a problem to do so or look like we understood how to build it but
    > now we get also the same mixed idea if we click on other languages front
    > page. How do I restrict the mixed, fresh releases to appear only with
    > English and the other languages would be pure, only that language
    > translations that is selected to as viewed?
    >
    > I hope you can understand what is the idea.
    >
    > Gene
    >
  • Thanks Mugur!

    We were making like this based on a sample template:

    {{ local }}
    {{ set_current_issue }}
    {{ unset_section }}
    {{ if $campsite->language->code = "en" }}
    {{ assign var="ignore_language" value="true" }}
    {{ else }}
    {{ assign var="ignore_language" value="false" }}
    {{ /if }}
    {{ list_articles length="10" constraints="type is Article onsection is
    on onfrontpage is on" ignore_language="$ignore_language"
    order="bynumber desc" }}
    onmouseover="this.style.backgroundColor='#DCF6D2'"
    style="cursor:pointer;cursor: hand;"
    onclick="document.location.href='{{ uri
    options="reset_subtitle_list" }}'"

    onmouseout="this.style.backgroundColor='#ffffff'">

    {{ $campsite->article->deck }}


    {{ $campsite->article->name }}


    {{ if $campsite->article->teaser_a != "" }}

    {{ $campsite->article->teaser_a }}


    {{ /if }}
    {{ if $campsite->article->teaser_b != "" }}

    height="5">{{ $campsite->article>teaser_a }}


    {{ /if }}
    {{ if $campsite->image->has_image1 }}

    {{ /if }}

    {{ $campsite->article-
    >intro }}




    {{ /list_articles }}
    {{ /local }}

    This is in the template home-middle.tpl that is the main column (2nd)
    for the site layout and the site goes blank on that area and towards
    right, left and top loads fine. So I guess there is some issue of
    nesting these or maybe because setting the languages there... I was
    just happy thinking understanding the templating and then it didn't
    work out again. Well, I'm sure there is a simple way though.

    Gene

    On 17.6.2009, at 13.27, Mugur Rus wrote:

    > Use the language data to decide how do you display the articles:
    >
    > {{ if $campsite->language->code = "en" }}
    > {{ assign var="ignore_language" value="true" }}
    > {{ else }}
    > {{ assign var="ignore_language" value="false" }}
    > {{ /if }}
    > {{ list_articles ignore_language=`$ignore_language` }}
    >
    > Hope this helps,
    > Mugur
    >
    > On Mon, Jun 15, 2009 at 10:13 PM, Generare Management Department > > wrote:
    > Hi!
    >
    > Here we are finetuning the content and the huge amount of languages.
    > Some languages are appearing only with few articles, some are more
    > common.
    >
    > We would like to have the English front page having mixed fresh
    > releases of articles.
    > It is not a problem to do so or look like we understood how to build
    > it but now we get also the same mixed idea if we click on other
    > languages front page. How do I restrict the mixed, fresh releases to
    > appear only with English and the other languages would be pure, only
    > that language translations that is selected to as viewed?
    >
    > I hope you can understand what is the idea.
    >
    > Gene
    >
  • Thanks!

    I tried the template but it messed our layout. No worries, I combined
    the good parts and now it works. Smile
    Although now it shows of course in English all the possible
    translations of the article (I did ask so, no worry), but could we
    make in a way that...

    if there is English -> show only English
    if there is other languages -> show in preferred order only the first
    one of the list (if Swedish, show that but not for example the French,
    or if Finnish show that)

    Because when we go to the articles itself, then we have flags that we
    can switch the same article in different languages that is available
    for it.

    Gene

    On 23.6.2009, at 12.53, Mugur Rus wrote:

    > Please use the attached template; the comparison is made using ==,
    > not = so the proper code is:
    > {{ if $campsite->language->code == "en" }}
    >
    > I also made some small optimizations; I removed the local statement
    > which is not needed and requires a lot of computing resources.
    >
    > Mugur
    >
    > On Mon, Jun 22, 2009 at 11:45 PM, Generare Management Department > > wrote:
    > Thanks Mugur!
    >
    > We were making like this based on a sample template:
    >
    > {{ local }}
    > {{ set_current_issue }}
    > {{ unset_section }}
    > {{ if $campsite->language->code = "en" }}
    > {{ assign var="ignore_language" value="true" }}
    > {{ else }}
    > {{ assign var="ignore_language" value="false" }}
    > {{ /if }}
    > {{ list_articles length="10" constraints="type is Article onsection
    > is on onfrontpage is on" ignore_language="$ignore_language"
    > order="bynumber desc" }}
    > > onmouseover="this.style.backgroundColor='#DCF6D2'"
    > style="cursor:pointer;cursor: hand;"
    > onclick="document.location.href='{{ uri
    > options="reset_subtitle_list" }}'"
    >
    > onmouseout="this.style.backgroundColor='#ffffff'">
    >

    {{ $campsite->article->deck }}


    >

    {{ $campsite->article->name }}


    > {{ if $campsite->article->teaser_a != "" }}
    >

    {{ $campsite->article->teaser_a }}


    > {{ /if }}
    > {{ if $campsite->article->teaser_b != "" }}
    >

    > height="5">{{ $campsite->article>teaser_a }}


    > {{ /if }}
    > {{ if $campsite->image->has_image1 }}
    >

    > {{ /if }}
    >

    {{ $campsite->article-
    > >intro }}


    >
    >
    > {{ /list_articles }}
    > {{ /local }}
    >
    > This is in the template home-middle.tpl that is the main column
    > (2nd) for the site layout and the site goes blank on that area and
    > towards right, left and top loads fine. So I guess there is some
    > issue of nesting these or maybe because setting the languages
    > there... I was just happy thinking understanding the templating and
    > then it didn't work out again. Well, I'm sure there is a simple way
    > though.
    >
    > Gene
    >
    > On 17.6.2009, at 13.27, Mugur Rus wrote:
    >
    >> Use the language data to decide how do you display the articles:
    >>
    >> {{ if $campsite->language->code = "en" }}
    >> {{ assign var="ignore_language" value="true" }}
    >> {{ else }}
    >> {{ assign var="ignore_language" value="false" }}
    >> {{ /if }}
    >> {{ list_articles ignore_language=`$ignore_language` }}
    >>
    >> Hope this helps,
    >> Mugur
    >>
    >> On Mon, Jun 15, 2009 at 10:13 PM, Generare Management Department >> > wrote:
    >> Hi!
    >>
    >> Here we are finetuning the content and the huge amount of languages.
    >> Some languages are appearing only with few articles, some are more
    >> common.
    >>
    >> We would like to have the English front page having mixed fresh
    >> releases of articles.
    >> It is not a problem to do so or look like we understood how to
    >> build it but now we get also the same mixed idea if we click on
    >> other languages front page. How do I restrict the mixed, fresh
    >> releases to appear only with English and the other languages would
    >> be pure, only that language translations that is selected to as
    >> viewed?
    >>
    >> I hope you can understand what is the idea.
    >>
    >> Gene
    >>
    >
    >
    >
    >
    >
    >
  • Use list_languages (see
    http://code.campware.org/manuals/campsite/3.3/index.php?id=303)

    E.g.:
    {{ list_languages of_article="true" }} will list all article translations.

    Mugur

    On Tue, Jun 23, 2009 at 3:38 PM, Generare Management Department <
    management@generare.com> wrote:

    > Thanks!
    > I tried the template but it messed our layout. No worries, I combined the
    > good parts and now it works. Smile
    > Although now it shows of course in English all the possible translations of
    > the article (I did ask so, no worry), but could we make in a way that...
    >
    > if there is English -> show only English
    > if there is other languages -> show in preferred order only the first one
    > of the list (if Swedish, show that but not for example the French, or if
    > Finnish show that)
    >
    > Because when we go to the articles itself, then we have flags that we can
    > switch the same article in different languages that is available for it.
    >
    > Gene
    >
    > On 23.6.2009, at 12.53, Mugur Rus wrote:
    >
    > Please use the attached template; the comparison is made using ==, not = so
    > the proper code is:
    > {{ if $campsite->language->code == "en" }}
    >
    > I also made some small optimizations; I removed the local statement which
    > is not needed and requires a lot of computing resources.
    >
    > Mugur
    >
    > On Mon, Jun 22, 2009 at 11:45 PM, Generare Management Department <
    > management@generare.com> wrote:
    >
    >> Thanks Mugur!
    >> We were making like this based on a sample template:
    >>
    >> {{ local }}
    >> {{ set_current_issue }}
    >> {{ unset_section }}
    >> {{ if $campsite->language->code = "en" }}
    >> {{ assign var="ignore_language" value="true" }}
    >> {{ else }}
    >> {{ assign var="ignore_language" value="false" }}
    >> {{ /if }}
    >> {{ list_articles length="10" constraints="type is Article onsection is on
    >> onfrontpage is on" ignore_language="$ignore_language" order="bynumber desc"
    >> }}
    >> >> onmouseover="this.style.backgroundColor='#DCF6D2'"
    >> style="cursor:pointer;cursor: hand;"
    >> onclick="document.location.href='{{ uri
    >> options="reset_subtitle_list" }}'"
    >> onmouseout="this.style.backgroundColor='#ffffff'">
    >>

    {{ $campsite->article->deck }}


    >>

    {{ $campsite->article->name }}


    >> {{ if $campsite->article->teaser_a != "" }}
    >>

    {{ $campsite->article->teaser_a }}


    >> {{ /if }}
    >> {{ if $campsite->article->teaser_b != "" }}
    >>

    >> height="5">{{ $campsite->article>teaser_a }}


    >> {{ /if }}
    >> {{ if $campsite->image->has_image1 }}
    >>

    >> {{ /if }}
    >>

    {{ $campsite->article->intro }}


    >>
    >>
    >> {{ /list_articles }}
    >> {{ /local }}
    >>
    >> This is in the template home-middle.tpl that is the main column (2nd) for
    >> the site layout and the site goes blank on that area and towards right, left
    >> and top loads fine. So I guess there is some issue of nesting these or maybe
    >> because setting the languages there... I was just happy thinking
    >> understanding the templating and then it didn't work out again. Well, I'm
    >> sure there is a simple way though.
    >>
    >> Gene
    >>
    >> On 17.6.2009, at 13.27, Mugur Rus wrote:
    >>
    >> Use the language data to decide how do you display the articles:
    >>
    >> {{ if $campsite->language->code = "en" }}
    >> {{ assign var="ignore_language" value="true" }}
    >> {{ else }}
    >> {{ assign var="ignore_language" value="false" }}
    >> {{ /if }}
    >> {{ list_articles ignore_language=`$ignore_language` }}
    >>
    >> Hope this helps,
    >> Mugur
    >>
    >> On Mon, Jun 15, 2009 at 10:13 PM, Generare Management Department <
    >> management@generare.com> wrote:
    >>
    >>> Hi!
    >>>
    >>> Here we are finetuning the content and the huge amount of languages.
    >>> Some languages are appearing only with few articles, some are more
    >>> common.
    >>>
    >>> We would like to have the English front page having mixed fresh releases
    >>> of articles.
    >>> It is not a problem to do so or look like we understood how to build it
    >>> but now we get also the same mixed idea if we click on other languages front
    >>> page. How do I restrict the mixed, fresh releases to appear only with
    >>> English and the other languages would be pure, only that language
    >>> translations that is selected to as viewed?
    >>>
    >>> I hope you can understand what is the idea.
    >>>
    >>> Gene
    >>>
    >>
    >>
    >>
    >>
    >>
    >>
    >
    >
    >
    >
    >
    >
    >
    >
  • Hi,

    can I restrict the output of listing for one translation per article?
    Mugur gave a great idea for the template that we modified for our
    layout.
    But the problem is that we still get like 5 different translations of
    the same article when we would need only one (it's quite boring to
    list the same article translations and then the list of 10 fits no
    other articles at all).

    So now it shows in our English page:
    - correctly ignores the language and shows all the recent articles in
    any language
    - incorrectly shows all the translations of the same article as recent
    articles
    -> we want to restrict the listing for 1 translation per article
    (preferring English if it exists)

    Like this:

    > if there is English -> show only English
    > if there is other languages -> show in preferred order only the
    > first one of the list (if Swedish, show that but not for example the
    > French, or if Finnish show that)

    Sanna @ gene

    On 23.6.2009, at 15.38, Generare Management Department wrote:

    > Thanks!
    >
    > I tried the template but it messed our layout. No worries, I
    > combined the good parts and now it works. Smile
    > Although now it shows of course in English all the possible
    > translations of the article (I did ask so, no worry), but could we
    > make in a way that...
    >
    > if there is English -> show only English
    > if there is other languages -> show in preferred order only the
    > first one of the list (if Swedish, show that but not for example the
    > French, or if Finnish show that)
    >
    > Because when we go to the articles itself, then we have flags that
    > we can switch the same article in different languages that is
    > available for it.
    >
    > Gene
    >
    > On 23.6.2009, at 12.53, Mugur Rus wrote:
    >
    >> Please use the attached template; the comparison is made using ==,
    >> not = so the proper code is:
    >> {{ if $campsite->language->code == "en" }}
    >>
    >> I also made some small optimizations; I removed the local statement
    >> which is not needed and requires a lot of computing resources.
    >>
    >> Mugur
    >>
    >> On Mon, Jun 22, 2009 at 11:45 PM, Generare Management Department >> > wrote:
    >> Thanks Mugur!
    >>
    >> We were making like this based on a sample template:
    >>
    >> {{ local }}
    >> {{ set_current_issue }}
    >> {{ unset_section }}
    >> {{ if $campsite->language->code = "en" }}
    >> {{ assign var="ignore_language" value="true" }}
    >> {{ else }}
    >> {{ assign var="ignore_language" value="false" }}
    >> {{ /if }}
    >> {{ list_articles length="10" constraints="type is Article onsection
    >> is on onfrontpage is on" ignore_language="$ignore_language"
    >> order="bynumber desc" }}
    >> >> onmouseover="this.style.backgroundColor='#DCF6D2'"
    >> style="cursor:pointer;cursor: hand;"
    >> onclick="document.location.href='{{ uri
    >> options="reset_subtitle_list" }}'"
    >>
    >> onmouseout="this.style.backgroundColor='#ffffff'">
    >>

    {{ $campsite->article->deck }}


    >>

    {{ $campsite->article->name }}


    >> {{ if $campsite->article->teaser_a != "" }}
    >>

    {{ $campsite->article->teaser_a }}


    >> {{ /if }}
    >> {{ if $campsite->article->teaser_b != "" }}
    >>

    >> height="5">{{ $campsite->article>teaser_a }}


    >> {{ /if }}
    >> {{ if $campsite->image->has_image1 }}
    >>

    >> {{ /if }}
    >>

    {{ $campsite->article-
    >> >intro }}


    >>
    >>
    >> {{ /list_articles }}
    >> {{ /local }}
    >>
    >> This is in the template home-middle.tpl that is the main column
    >> (2nd) for the site layout and the site goes blank on that area and
    >> towards right, left and top loads fine. So I guess there is some
    >> issue of nesting these or maybe because setting the languages
    >> there... I was just happy thinking understanding the templating and
    >> then it didn't work out again. Well, I'm sure there is a simple way
    >> though.
    >>
    >> Gene
    >>
    >> On 17.6.2009, at 13.27, Mugur Rus wrote:
    >>
    >>> Use the language data to decide how do you display the articles:
    >>>
    >>> {{ if $campsite->language->code = "en" }}
    >>> {{ assign var="ignore_language" value="true" }}
    >>> {{ else }}
    >>> {{ assign var="ignore_language" value="false" }}
    >>> {{ /if }}
    >>> {{ list_articles ignore_language=`$ignore_language` }}
    >>>
    >>> Hope this helps,
    >>> Mugur
    >>>
    >>> On Mon, Jun 15, 2009 at 10:13 PM, Generare Management Department >>> > wrote:
    >>> Hi!
    >>>
    >>> Here we are finetuning the content and the huge amount of languages.
    >>> Some languages are appearing only with few articles, some are more
    >>> common.
    >>>
    >>> We would like to have the English front page having mixed fresh
    >>> releases of articles.
    >>> It is not a problem to do so or look like we understood how to
    >>> build it but now we get also the same mixed idea if we click on
    >>> other languages front page. How do I restrict the mixed, fresh
    >>> releases to appear only with English and the other languages would
    >>> be pure, only that language translations that is selected to as
    >>> viewed?
    >>>
    >>> I hope you can understand what is the idea.
    >>>
    >>> Gene
    >>>
    >>
    >>
    >>
    >>
    >>
    >>
    >
    >
  • You can restrict any list to any length you want: length="1"

    {{ list_languages of_article="true" exclude_current="true" length="1" }}

    If you want English to be used whenever possible use: order="byNumber asc"

    The English language is the first in the table and has the smallest
    identifier so it will always be the first. Of course, this way is less than
    ideal to order languages so we can implement in the future a system of
    language priority for a certain publication.

    Mugur

    On Thu, Jul 23, 2009 at 12:57 PM, Generare Management Department <
    management@generare.com> wrote:

    > Hi,
    > can I restrict the output of listing for one translation per article?
    > Mugur gave a great idea for the template that we modified for our layout.
    > But the problem is that we still get like 5 different translations of the
    > same article when we would need only one (it's quite boring to list the same
    > article translations and then the list of 10 fits no other articles at all).
    >
    > So now it shows in our English page:
    > - correctly ignores the language and shows all the recent articles in any
    > language
    > - incorrectly shows all the translations of the same article as recent
    > articles
    > -> we want to restrict the listing for 1 translation per article
    > (preferring English if it exists)
    >
    > Like this:
    >
    > if there is English -> show only English
    > if there is other languages -> show in preferred order only the first one
    > of the list (if Swedish, show that but not for example the French, or if
    > Finnish show that)
    >
    >
    > Sanna @ gene
    >
    > On 23.6.2009, at 15.38, Generare Management Department wrote:
    >
    > Thanks!
    > I tried the template but it messed our layout. No worries, I combined the
    > good parts and now it works. Smile
    > Although now it shows of course in English all the possible translations of
    > the article (I did ask so, no worry), but could we make in a way that...
    >
    > if there is English -> show only English
    > if there is other languages -> show in preferred order only the first one
    > of the list (if Swedish, show that but not for example the French, or if
    > Finnish show that)
    >
    > Because when we go to the articles itself, then we have flags that we can
    > switch the same article in different languages that is available for it.
    >
    > Gene
    >
    > On 23.6.2009, at 12.53, Mugur Rus wrote:
    >
    > Please use the attached template; the comparison is made using ==, not = so
    > the proper code is:
    > {{ if $campsite->language->code == "en" }}
    >
    > I also made some small optimizations; I removed the local statement which
    > is not needed and requires a lot of computing resources.
    >
    > Mugur
    >
    > On Mon, Jun 22, 2009 at 11:45 PM, Generare Management Department <
    > management@generare.com> wrote:
    >
    >> Thanks Mugur!
    >> We were making like this based on a sample template:
    >>
    >> {{ local }}
    >> {{ set_current_issue }}
    >> {{ unset_section }}
    >> {{ if $campsite->language->code = "en" }}
    >> {{ assign var="ignore_language" value="true" }}
    >> {{ else }}
    >> {{ assign var="ignore_language" value="false" }}
    >> {{ /if }}
    >> {{ list_articles length="10" constraints="type is Article onsection is on
    >> onfrontpage is on" ignore_language="$ignore_language" order="bynumber desc"
    >> }}
    >> >> onmouseover="this.style.backgroundColor='#DCF6D2'"
    >> style="cursor:pointer;cursor: hand;"
    >> onclick="document.location.href='{{ uri
    >> options="reset_subtitle_list" }}'"
    >> onmouseout="this.style.backgroundColor='#ffffff'">
    >>

    {{ $campsite->article->deck }}


    >>

    {{ $campsite->article->name }}


    >> {{ if $campsite->article->teaser_a != "" }}
    >>

    {{ $campsite->article->teaser_a }}


    >> {{ /if }}
    >> {{ if $campsite->article->teaser_b != "" }}
    >>

    >> height="5">{{ $campsite->article>teaser_a }}


    >> {{ /if }}
    >> {{ if $campsite->image->has_image1 }}
    >>

    >> {{ /if }}
    >>

    {{ $campsite->article->intro }}


    >>
    >>
    >> {{ /list_articles }}
    >> {{ /local }}
    >>
    >> This is in the template home-middle.tpl that is the main column (2nd) for
    >> the site layout and the site goes blank on that area and towards right, left
    >> and top loads fine. So I guess there is some issue of nesting these or maybe
    >> because setting the languages there... I was just happy thinking
    >> understanding the templating and then it didn't work out again. Well, I'm
    >> sure there is a simple way though.
    >>
    >> Gene
    >>
    >> On 17.6.2009, at 13.27, Mugur Rus wrote:
    >>
    >> Use the language data to decide how do you display the articles:
    >>
    >> {{ if $campsite->language->code = "en" }}
    >> {{ assign var="ignore_language" value="true" }}
    >> {{ else }}
    >> {{ assign var="ignore_language" value="false" }}
    >> {{ /if }}
    >> {{ list_articles ignore_language=`$ignore_language` }}
    >>
    >> Hope this helps,
    >> Mugur
    >>
    >> On Mon, Jun 15, 2009 at 10:13 PM, Generare Management Department <
    >> management@generare.com> wrote:
    >>
    >>> Hi!
    >>>
    >>> Here we are finetuning the content and the huge amount of languages.
    >>> Some languages are appearing only with few articles, some are more
    >>> common.
    >>>
    >>> We would like to have the English front page having mixed fresh releases
    >>> of articles.
    >>> It is not a problem to do so or look like we understood how to build it
    >>> but now we get also the same mixed idea if we click on other languages front
    >>> page. How do I restrict the mixed, fresh releases to appear only with
    >>> English and the other languages would be pure, only that language
    >>> translations that is selected to as viewed?
    >>>
    >>> I hope you can understand what is the idea.
    >>>
    >>> Gene
    >>>
    >>
    >>
    >>
    >>
    >>
    >>
    >
    >
    >
    >
    >
    >
    >
  • Yes,
    I kind of restricted the length for testing purposes to see what comes
    etc.
    The real idea would be anyway to have like 10 newest articles on the
    first page (just boring if they are the same article but different
    translations but we look that later).
    The question is now:
    how do I paginate the articles listing like on the first page 10
    newest, then 10 next ones, more 10 etc. until certain amount of total
    newest (for example 50 newest altogether).

    I was sure there was something like that in the manual but can't find
    it or maybe it was something else...

    /Sanna

    On 27.7.2009, at 14.03, Mugur Rus wrote:

    > You can restrict any list to any length you want: length="1"
    >
    > {{ list_languages of_article="true" exclude_current="true"
    > length="1" }}
    >
    > If you want English to be used whenever possible use:
    > order="byNumber asc"
    >
    > The English language is the first in the table and has the smallest
    > identifier so it will always be the first. Of course, this way is
    > less than ideal to order languages so we can implement in the future
    > a system of language priority for a certain publication.
    >
    > Mugur
    >
    > On Thu, Jul 23, 2009 at 12:57 PM, Generare Management Department > > wrote:
    > Hi,
    >
    > can I restrict the output of listing for one translation per article?
    > Mugur gave a great idea for the template that we modified for our
    > layout.
    > But the problem is that we still get like 5 different translations
    > of the same article when we would need only one (it's quite boring
    > to list the same article translations and then the list of 10 fits
    > no other articles at all).
    >
    > So now it shows in our English page:
    > - correctly ignores the language and shows all the recent articles
    > in any language
    > - incorrectly shows all the translations of the same article as
    > recent articles
    > -> we want to restrict the listing for 1 translation per article
    > (preferring English if it exists)
    >
    > Like this:
    >
    >> if there is English -> show only English
    >> if there is other languages -> show in preferred order only the
    >> first one of the list (if Swedish, show that but not for example
    >> the French, or if Finnish show that)
    >
    > Sanna @ gene
    >
    > On 23.6.2009, at 15.38, Generare Management Department wrote:
    >
    >> Thanks!
    >>
    >> I tried the template but it messed our layout. No worries, I
    >> combined the good parts and now it works. Smile
    >> Although now it shows of course in English all the possible
    >> translations of the article (I did ask so, no worry), but could we
    >> make in a way that...
    >>
    >> if there is English -> show only English
    >> if there is other languages -> show in preferred order only the
    >> first one of the list (if Swedish, show that but not for example
    >> the French, or if Finnish show that)
    >>
    >> Because when we go to the articles itself, then we have flags that
    >> we can switch the same article in different languages that is
    >> available for it.
    >>
    >> Gene
    >>
    >> On 23.6.2009, at 12.53, Mugur Rus wrote:
    >>
    >>> Please use the attached template; the comparison is made using ==,
    >>> not = so the proper code is:
    >>> {{ if $campsite->language->code == "en" }}
    >>>
    >>> I also made some small optimizations; I removed the local
    >>> statement which is not needed and requires a lot of computing
    >>> resources.
    >>>
    >>> Mugur
    >>>
    >>> On Mon, Jun 22, 2009 at 11:45 PM, Generare Management Department >>> > wrote:
    >>> Thanks Mugur!
    >>>
    >>> We were making like this based on a sample template:
    >>>
    >>> {{ local }}
    >>> {{ set_current_issue }}
    >>> {{ unset_section }}
    >>> {{ if $campsite->language->code = "en" }}
    >>> {{ assign var="ignore_language" value="true" }}
    >>> {{ else }}
    >>> {{ assign var="ignore_language" value="false" }}
    >>> {{ /if }}
    >>> {{ list_articles length="10" constraints="type is Article
    >>> onsection is on onfrontpage is on"
    >>> ignore_language="$ignore_language" order="bynumber desc" }}
    >>> >>> onmouseover="this.style.backgroundColor='#DCF6D2'"
    >>> style="cursor:pointer;cursor: hand;"
    >>> onclick="document.location.href='{{ uri
    >>> options="reset_subtitle_list" }}'"
    >>>
    >>> onmouseout="this.style.backgroundColor='#ffffff'">
    >>>

    {{ $campsite->article->deck }}


    >>>

    {{ $campsite->article->name }}


    >>> {{ if $campsite->article->teaser_a != "" }}
    >>>

    {{ $campsite->article->teaser_a }}


    >>> {{ /if }}
    >>> {{ if $campsite->article->teaser_b != "" }}
    >>>

    >>> width="8" height="5">{{ $campsite->article>teaser_a }}


    >>> {{ /if }}
    >>> {{ if $campsite->image->has_image1 }}
    >>>

    >>> {{ /if }}
    >>>

    {{ $campsite->article-
    >>> >intro }}


    >>>
    >>>
    >>> {{ /list_articles }}
    >>> {{ /local }}
    >>>
    >>> This is in the template home-middle.tpl that is the main column
    >>> (2nd) for the site layout and the site goes blank on that area and
    >>> towards right, left and top loads fine. So I guess there is some
    >>> issue of nesting these or maybe because setting the languages
    >>> there... I was just happy thinking understanding the templating
    >>> and then it didn't work out again. Well, I'm sure there is a
    >>> simple way though.
    >>>
    >>> Gene
    >>>
    >>> On 17.6.2009, at 13.27, Mugur Rus wrote:
    >>>
    >>>> Use the language data to decide how do you display the articles:
    >>>>
    >>>> {{ if $campsite->language->code = "en" }}
    >>>> {{ assign var="ignore_language" value="true" }}
    >>>> {{ else }}
    >>>> {{ assign var="ignore_language" value="false" }}
    >>>> {{ /if }}
    >>>> {{ list_articles ignore_language=`$ignore_language` }}
    >>>>
    >>>> Hope this helps,
    >>>> Mugur
    >>>>
    >>>> On Mon, Jun 15, 2009 at 10:13 PM, Generare Management Department >>>> > wrote:
    >>>> Hi!
    >>>>
    >>>> Here we are finetuning the content and the huge amount of
    >>>> languages.
    >>>> Some languages are appearing only with few articles, some are
    >>>> more common.
    >>>>
    >>>> We would like to have the English front page having mixed fresh
    >>>> releases of articles.
    >>>> It is not a problem to do so or look like we understood how to
    >>>> build it but now we get also the same mixed idea if we click on
    >>>> other languages front page. How do I restrict the mixed, fresh
    >>>> releases to appear only with English and the other languages
    >>>> would be pure, only that language translations that is selected
    >>>> to as viewed?
    >>>>
    >>>> I hope you can understand what is the idea.
    >>>>
    >>>> Gene
    >>>>
    >>>
    >>>
    >>>
    >>>
    >>>
    >>
    >>
    >
    >
  • Is the pagination for listing articles something to do with "currrent
    list"?
    It should have been that English language have "mixed" many languages
    but other languages should have only their own article translations.
    Now also the other languages get all different versions of the same
    article listed.
    Need to focus more on what Mugur sent... maybe I changed something and
    just can't remember...

    Sanna

    On 27.7.2009, at 23.37, Generare Management Department wrote:

    > Yes,
    > I kind of restricted the length for testing purposes to see what
    > comes etc.
    > The real idea would be anyway to have like 10 newest articles on the
    > first page (just boring if they are the same article but different
    > translations but we look that later).
    > The question is now:
    > how do I paginate the articles listing like on the first page 10
    > newest, then 10 next ones, more 10 etc. until certain amount of
    > total newest (for example 50 newest altogether).
    >
    > I was sure there was something like that in the manual but can't
    > find it or maybe it was something else...
    >
    > /Sanna
    >
    > On 27.7.2009, at 14.03, Mugur Rus wrote:
    >
    >> You can restrict any list to any length you want: length="1"
    >>
    >> {{ list_languages of_article="true" exclude_current="true"
    >> length="1" }}
    >>
    >> If you want English to be used whenever possible use:
    >> order="byNumber asc"
    >>
    >> The English language is the first in the table and has the smallest
    >> identifier so it will always be the first. Of course, this way is
    >> less than ideal to order languages so we can implement in the
    >> future a system of language priority for a certain publication.
    >>
    >> Mugur
    >>
    >> On Thu, Jul 23, 2009 at 12:57 PM, Generare Management Department >> > wrote:
    >> Hi,
    >>
    >> can I restrict the output of listing for one translation per article?
    >> Mugur gave a great idea for the template that we modified for our
    >> layout.
    >> But the problem is that we still get like 5 different translations
    >> of the same article when we would need only one (it's quite boring
    >> to list the same article translations and then the list of 10 fits
    >> no other articles at all).
    >>
    >> So now it shows in our English page:
    >> - correctly ignores the language and shows all the recent articles
    >> in any language
    >> - incorrectly shows all the translations of the same article as
    >> recent articles
    >> -> we want to restrict the listing for 1 translation per article
    >> (preferring English if it exists)
    >>
    >> Like this:
    >>
    >>> if there is English -> show only English
    >>> if there is other languages -> show in preferred order only the
    >>> first one of the list (if Swedish, show that but not for example
    >>> the French, or if Finnish show that)
    >>
    >> Sanna @ gene
    >>
    >> On 23.6.2009, at 15.38, Generare Management Department wrote:
    >>
    >>> Thanks!
    >>>
    >>> I tried the template but it messed our layout. No worries, I
    >>> combined the good parts and now it works. Smile
    >>> Although now it shows of course in English all the possible
    >>> translations of the article (I did ask so, no worry), but could we
    >>> make in a way that...
    >>>
    >>> if there is English -> show only English
    >>> if there is other languages -> show in preferred order only the
    >>> first one of the list (if Swedish, show that but not for example
    >>> the French, or if Finnish show that)
    >>>
    >>> Because when we go to the articles itself, then we have flags that
    >>> we can switch the same article in different languages that is
    >>> available for it.
    >>>
    >>> Gene
    >>>
    >>> On 23.6.2009, at 12.53, Mugur Rus wrote:
    >>>
    >>>> Please use the attached template; the comparison is made using
    >>>> ==, not = so the proper code is:
    >>>> {{ if $campsite->language->code == "en" }}
    >>>>
    >>>> I also made some small optimizations; I removed the local
    >>>> statement which is not needed and requires a lot of computing
    >>>> resources.
    >>>>
    >>>> Mugur
    >>>>
    >>>> On Mon, Jun 22, 2009 at 11:45 PM, Generare Management Department >>>> > wrote:
    >>>> Thanks Mugur!
    >>>>
    >>>> We were making like this based on a sample template:
    >>>>
    >>>> {{ local }}
    >>>> {{ set_current_issue }}
    >>>> {{ unset_section }}
    >>>> {{ if $campsite->language->code = "en" }}
    >>>> {{ assign var="ignore_language" value="true" }}
    >>>> {{ else }}
    >>>> {{ assign var="ignore_language" value="false" }}
    >>>> {{ /if }}
    >>>> {{ list_articles length="10" constraints="type is Article
    >>>> onsection is on onfrontpage is on"
    >>>> ignore_language="$ignore_language" order="bynumber desc" }}
    >>>> >>>> onmouseover="this.style.backgroundColor='#DCF6D2'"
    >>>> style="cursor:pointer;cursor: hand;"
    >>>> onclick="document.location.href='{{ uri
    >>>> options="reset_subtitle_list" }}'"
    >>>>
    >>>> onmouseout="this.style.backgroundColor='#ffffff'">
    >>>>

    {{ $campsite->article->deck }}


    >>>>

    {{ $campsite->article->name }}


    >>>> {{ if $campsite->article->teaser_a != "" }}
    >>>>

    {{ $campsite->article->teaser_a }}


    >>>> {{ /if }}
    >>>> {{ if $campsite->article->teaser_b != "" }}
    >>>>

    >>>> width="8" height="5">{{ $campsite->article>teaser_a }}


    >>>> {{ /if }}
    >>>> {{ if $campsite->image->has_image1 }}
    >>>>
    >>>> div>
    >>>> {{ /if }}
    >>>>

    {{ $campsite->article-
    >>>> >intro }}


    >>>>
    >>>>
    >>>> {{ /list_articles }}
    >>>> {{ /local }}
    >>>>
    >>>> This is in the template home-middle.tpl that is the main column
    >>>> (2nd) for the site layout and the site goes blank on that area
    >>>> and towards right, left and top loads fine. So I guess there is
    >>>> some issue of nesting these or maybe because setting the
    >>>> languages there... I was just happy thinking understanding the
    >>>> templating and then it didn't work out again. Well, I'm sure
    >>>> there is a simple way though.
    >>>>
    >>>> Gene
    >>>>
    >>>> On 17.6.2009, at 13.27, Mugur Rus wrote:
    >>>>
    >>>>> Use the language data to decide how do you display the articles:
    >>>>>
    >>>>> {{ if $campsite->language->code = "en" }}
    >>>>> {{ assign var="ignore_language" value="true" }}
    >>>>> {{ else }}
    >>>>> {{ assign var="ignore_language" value="false" }}
    >>>>> {{ /if }}
    >>>>> {{ list_articles ignore_language=`$ignore_language` }}
    >>>>>
    >>>>> Hope this helps,
    >>>>> Mugur
    >>>>>
    >>>>> On Mon, Jun 15, 2009 at 10:13 PM, Generare Management Department
    >>>>> wrote:
    >>>>> Hi!
    >>>>>
    >>>>> Here we are finetuning the content and the huge amount of
    >>>>> languages.
    >>>>> Some languages are appearing only with few articles, some are
    >>>>> more common.
    >>>>>
    >>>>> We would like to have the English front page having mixed fresh
    >>>>> releases of articles.
    >>>>> It is not a problem to do so or look like we understood how to
    >>>>> build it but now we get also the same mixed idea if we click on
    >>>>> other languages front page. How do I restrict the mixed, fresh
    >>>>> releases to appear only with English and the other languages
    >>>>> would be pure, only that language translations that is selected
    >>>>> to as viewed?
    >>>>>
    >>>>> I hope you can understand what is the idea.
    >>>>>
    >>>>> Gene
    >>>>>
    >>>>
    >>>>
    >>>>
    >>>>
    >>>>
    >>>
    >>>
    >>
    >>
    >
    >
  • Hi!

    So, to make a short summary:


    > So now it shows in our English page:
    > - correctly ignores the language and shows all the recent articles
    > in any language
    > - incorrectly shows all the translations of the same article as
    > recent articles
    > -> we want to restrict the listing for 1 translation per article
    > (preferring English if it exists)

    So, I understood from Mugur's answer on 27th of July that it is not
    practically possible to restrict the output in a way we want:

    > Like this in ENGLISH page:
    >
    > if there is English -> show only English
    > if there is other languages -> show in preferred order only the
    > first one of the list (if Swedish, show that but not for example the
    > French, or if Finnish show that)

    CONCLUSION:

    -> We keep the English giving all the possible article translations of
    all fresh releases BUT we ADD a pagination.
    -> For other language we need to restrict to show only those languages
    that for some reason is not working right now and I do not see
    anything wrong in the logic that Mugur earlier made for it (template
    attached)

    (-> then we need to still figure the troubles of "the advanced search"
    what is another thread here)

    We are just very late already with the release of the news site here!
    Campsite is -imho - very powerful but yet so many obstacles has arised
    along the way that it was not something we could have foreseen even if
    we have quite a lot of experience on studying new open source systems.
    So, very potential system but of course it is never happy to find some
    bugs or stumble in the lack of knowledge how to do something with a
    new system.

    Kind regards,

    Sanna @ Gene




    On 28.7.2009, at 23.27, Generare Management Department wrote:

    > Is the pagination for listing articles something to do with
    > "currrent list"?
    > It should have been that English language have "mixed" many
    > languages but other languages should have only their own article
    > translations. Now also the other languages get all different
    > versions of the same article listed.
    > Need to focus more on what Mugur sent... maybe I changed something
    > and just can't remember...
    >
    > Sanna
    >
    > On 27.7.2009, at 23.37, Generare Management Department wrote:
    >
    >> Yes,
    >> I kind of restricted the length for testing purposes to see what
    >> comes etc.
    >> The real idea would be anyway to have like 10 newest articles on
    >> the first page (just boring if they are the same article but
    >> different translations but we look that later).
    >> The question is now:
    >> how do I paginate the articles listing like on the first page 10
    >> newest, then 10 next ones, more 10 etc. until certain amount of
    >> total newest (for example 50 newest altogether).
    >>
    >> I was sure there was something like that in the manual but can't
    >> find it or maybe it was something else...
    >>
    >> /Sanna
    >>
    >> On 27.7.2009, at 14.03, Mugur Rus wrote:
    >>
    >>> You can restrict any list to any length you want: length="1"
    >>>
    >>> {{ list_languages of_article="true" exclude_current="true"
    >>> length="1" }}
    >>>
    >>> If you want English to be used whenever possible use:
    >>> order="byNumber asc"
    >>>
    >>> The English language is the first in the table and has the
    >>> smallest identifier so it will always be the first. Of course,
    >>> this way is less than ideal to order languages so we can implement
    >>> in the future a system of language priority for a certain
    >>> publication.
    >>>
    >>> Mugur
    >>>
    >>> On Thu, Jul 23, 2009 at 12:57 PM, Generare Management Department >>> > wrote:
    >>> Hi,
    >>>
    >>> can I restrict the output of listing for one translation per
    >>> article?
    >>> Mugur gave a great idea for the template that we modified for our
    >>> layout.
    >>> But the problem is that we still get like 5 different translations
    >>> of the same article when we would need only one (it's quite boring
    >>> to list the same article translations and then the list of 10 fits
    >>> no other articles at all).
    >>>
    >>> So now it shows in our English page:
    >>> - correctly ignores the language and shows all the recent articles
    >>> in any language
    >>> - incorrectly shows all the translations of the same article as
    >>> recent articles
    >>> -> we want to restrict the listing for 1 translation per article
    >>> (preferring English if it exists)
    >>>
    >>> Like this:
    >>>
    >>>> if there is English -> show only English
    >>>> if there is other languages -> show in preferred order only the
    >>>> first one of the list (if Swedish, show that but not for example
    >>>> the French, or if Finnish show that)
    >>>
    >>> Sanna @ gene
    >>>
    >>> On 23.6.2009, at 15.38, Generare Management Department wrote:
    >>>
    >>>> Thanks!
    >>>>
    >>>> I tried the template but it messed our layout. No worries, I
    >>>> combined the good parts and now it works. Smile
    >>>> Although now it shows of course in English all the possible
    >>>> translations of the article (I did ask so, no worry), but could
    >>>> we make in a way that...
    >>>>
    >>>> if there is English -> show only English
    >>>> if there is other languages -> show in preferred order only the
    >>>> first one of the list (if Swedish, show that but not for example
    >>>> the French, or if Finnish show that)
    >>>>
    >>>> Because when we go to the articles itself, then we have flags
    >>>> that we can switch the same article in different languages that
    >>>> is available for it.
    >>>>
    >>>> Gene
    >>>>
    >>>> On 23.6.2009, at 12.53, Mugur Rus wrote:
    >>>>
    >>>>> Please use the attached template; the comparison is made using
    >>>>> ==, not = so the proper code is:
    >>>>> {{ if $campsite->language->code == "en" }}
    >>>>>
    >>>>> I also made some small optimizations; I removed the local
    >>>>> statement which is not needed and requires a lot of computing
    >>>>> resources.
    >>>>>
    >>>>> Mugur
    >>>>>
    >>>>> On Mon, Jun 22, 2009 at 11:45 PM, Generare Management Department
    >>>>> wrote:
    >>>>> Thanks Mugur!
    >>>>>
    >>>>> We were making like this based on a sample template:
    >>>>>
    >>>>> {{ local }}
    >>>>> {{ set_current_issue }}
    >>>>> {{ unset_section }}
    >>>>> {{ if $campsite->language->code = "en" }}
    >>>>> {{ assign var="ignore_language" value="true" }}
    >>>>> {{ else }}
    >>>>> {{ assign var="ignore_language" value="false" }}
    >>>>> {{ /if }}
    >>>>> {{ list_articles length="10" constraints="type is Article
    >>>>> onsection is on onfrontpage is on"
    >>>>> ignore_language="$ignore_language" order="bynumber desc" }}
    >>>>> >>>>> onmouseover="this.style.backgroundColor='#DCF6D2'"
    >>>>> style="cursor:pointer;cursor: hand;"
    >>>>> onclick="document.location.href='{{ uri
    >>>>> options="reset_subtitle_list" }}'"
    >>>>>
    >>>>> onmouseout="this.style.backgroundColor='#ffffff'">
    >>>>>

    {{ $campsite->article->deck }}


    >>>>>

    {{ $campsite->article->name }}


    >>>>> {{ if $campsite->article->teaser_a != "" }}
    >>>>>

    {{ $campsite->article->teaser_a }} >>>>> p>
    >>>>> {{ /if }}
    >>>>> {{ if $campsite->article->teaser_b != "" }}
    >>>>>

    >>>>> width="8" height="5">{{ $campsite->article>teaser_a }}


    >>>>> {{ /if }}
    >>>>> {{ if $campsite->image->has_image1 }}
    >>>>>
    >>>>> div>
    >>>>> {{ /if }}
    >>>>>

    {{ $campsite->article-
    >>>>> >intro }}


    >>>>>
    >>>>>
    >>>>> {{ /list_articles }}
    >>>>> {{ /local }}
    >>>>>
    >>>>> This is in the template home-middle.tpl that is the main column
    >>>>> (2nd) for the site layout and the site goes blank on that area
    >>>>> and towards right, left and top loads fine. So I guess there is
    >>>>> some issue of nesting these or maybe because setting the
    >>>>> languages there... I was just happy thinking understanding the
    >>>>> templating and then it didn't work out again. Well, I'm sure
    >>>>> there is a simple way though.
    >>>>>
    >>>>> Gene
    >>>>>
    >>>>> On 17.6.2009, at 13.27, Mugur Rus wrote:
    >>>>>
    >>>>>> Use the language data to decide how do you display the articles:
    >>>>>>
    >>>>>> {{ if $campsite->language->code = "en" }}
    >>>>>> {{ assign var="ignore_language" value="true" }}
    >>>>>> {{ else }}
    >>>>>> {{ assign var="ignore_language" value="false" }}
    >>>>>> {{ /if }}
    >>>>>> {{ list_articles ignore_language=`$ignore_language` }}
    >>>>>>
    >>>>>> Hope this helps,
    >>>>>> Mugur
    >>>>>>
    >>>>>> On Mon, Jun 15, 2009 at 10:13 PM, Generare Management
    >>>>>> Department wrote:
    >>>>>> Hi!
    >>>>>>
    >>>>>> Here we are finetuning the content and the huge amount of
    >>>>>> languages.
    >>>>>> Some languages are appearing only with few articles, some are
    >>>>>> more common.
    >>>>>>
    >>>>>> We would like to have the English front page having mixed fresh
    >>>>>> releases of articles.
    >>>>>> It is not a problem to do so or look like we understood how to
    >>>>>> build it but now we get also the same mixed idea if we click on
    >>>>>> other languages front page. How do I restrict the mixed, fresh
    >>>>>> releases to appear only with English and the other languages
    >>>>>> would be pure, only that language translations that is selected
    >>>>>> to as viewed?
    >>>>>>
    >>>>>> I hope you can understand what is the idea.
    >>>>>>
    >>>>>> Gene
    >>>>>>
    >>>>>
    >>>>>
    >>>>>
    >>>>>
    >>>>>
    >>>>
    >>>>
    >>>
    >>>
  • The problem here may be some miscommunication; you said you wanted to
    display the latest news; OK, use list_articles, order them by the publish
    date and there you have them. But do not use the ignore_language parameter.
    This, of course, will list all article translations. I remember I said in a
    previous email, you need to list translations for each article in the list
    like this:

    {{ list_articles order="byPublishDate desc" }}
    display the article in the current language
    {{ list_languages of_article="true" exclude_current="true" }}
    display the article translation
    {{ /list_languages }}
    {{ /list_articles }}

    This way you get a list of the latest articles in the current language and
    their translations. Right now Campsite can't produce a list of articles from
    different languages and have only one translation of each article in the
    list.

    Mugur

    On Wed, Jul 29, 2009 at 1:40 PM, Generare Management Department <
    management@generare.com> wrote:

    > Hi!
    > So, to make a short summary:
    >
    > So now it shows in our English page:
    > - correctly ignores the language and shows all the recent articles in any
    > language
    > - incorrectly shows all the translations of the same article as recent
    > articles
    > -> we want to restrict the listing for 1 translation per article
    > (preferring English if it exists)
    >
    >
    > So, I understood from Mugur's answer on 27th of July that it is not
    > practically possible to restrict the output in a way we want:
    >
    > Like this in ENGLISH page:
    >
    > if there is English -> show only English
    > if there is other languages -> show in preferred order only the first one
    > of the list (if Swedish, show that but not for example the French, or if
    > Finnish show that)
    >
    > *
    > *
    > *CONCLUSION:*
    >
    > *-> We keep the English giving all the possible article translations of
    > all fresh releases BUT we ADD a pagination.*
    > *-> For other language we need to restrict to show only those languages
    > that for some reason is not working right now and I do not see anything
    > wrong in the logic that Mugur earlier made for it (template attached)*
    > *
    > *
    > *(-> then we need to still figure the
    > troubles of "the advanced search" what is another thread here)
    > *
    > We are just very late already with the release of the news site here!
    > Campsite is -imho - very powerful but yet so many obstacles has arised along
    > the way that it was not something we could have foreseen even if we have
    > quite a lot of experience on studying new open source systems. So, very
    > potential system but of course it is never happy to find some bugs or
    > stumble in the lack of knowledge how to do something with a new system.
    >
    > Kind regards,
    >
    > Sanna @ Gene
    >
    >
    >
    >
    > On 28.7.2009, at 23.27, Generare Management Department wrote:
    >
    > Is the pagination for listing articles something to do with "currrent
    > list"?It should have been that English language have "mixed" many
    > languages but other languages should have only their own article
    > translations. Now also the other languages get all different versions of the
    > same article listed.
    > Need to focus more on what Mugur sent... maybe I changed something and just
    > can't remember...
    >
    > Sanna
    >
    > On 27.7.2009, at 23.37, Generare Management Department wrote:
    >
    > Yes, I kind of restricted the length for testing purposes to see what
    > comes etc.
    > The real idea would be anyway to have like 10 newest articles on the first
    > page (just boring if they are the same article but different translations
    > but we look that later).
    > The question is now:
    > how do I paginate the articles listing like on the first page 10 newest,
    > then 10 next ones, more 10 etc. until certain amount of total newest (for
    > example 50 newest altogether).
    >
    > I was sure there was something like that in the manual but can't find it or
    > maybe it was something else...
    >
    > /Sanna
    >
    > On 27.7.2009, at 14.03, Mugur Rus wrote:
    >
    > You can restrict any list to any length you want: length="1"
    >
    > {{ list_languages of_article="true" exclude_current="true" length="1" }}
    >
    > If you want English to be used whenever possible use: order="byNumber asc"
    >
    > The English language is the first in the table and has the smallest
    > identifier so it will always be the first. Of course, this way is less than
    > ideal to order languages so we can implement in the future a system of
    > language priority for a certain publication.
    >
    > Mugur
    >
    > On Thu, Jul 23, 2009 at 12:57 PM, Generare Management Department <
    > management@generare.com> wrote:
    >
    >> Hi,
    >> can I restrict the output of listing for one translation per article?
    >> Mugur gave a great idea for the template that we modified for our layout.
    >> But the problem is that we still get like 5 different translations of the
    >> same article when we would need only one (it's quite boring to list the same
    >> article translations and then the list of 10 fits no other articles at all).
    >>
    >> So now it shows in our English page:
    >> - correctly ignores the language and shows all the recent articles in any
    >> language
    >> - incorrectly shows all the translations of the same article as recent
    >> articles
    >> -> we want to restrict the listing for 1 translation per article
    >> (preferring English if it exists)
    >>
    >> Like this:
    >>
    >> if there is English -> show only English
    >> if there is other languages -> show in preferred order only the first one
    >> of the list (if Swedish, show that but not for example the French, or if
    >> Finnish show that)
    >>
    >>
    >> Sanna @ gene
    >>
    >> On 23.6.2009, at 15.38, Generare Management Department wrote:
    >>
    >> Thanks!
    >> I tried the template but it messed our layout. No worries, I combined the
    >> good parts and now it works. Smile
    >> Although now it shows of course in English all the possible translations
    >> of the article (I did ask so, no worry), but could we make in a way that...
    >>
    >> if there is English -> show only English
    >> if there is other languages -> show in preferred order only the first one
    >> of the list (if Swedish, show that but not for example the French, or if
    >> Finnish show that)
    >>
    >> Because when we go to the articles itself, then we have flags that we can
    >> switch the same article in different languages that is available for it.
    >>
    >> Gene
    >>
    >> On 23.6.2009, at 12.53, Mugur Rus wrote:
    >>
    >> Please use the attached template; the comparison is made using ==, not =
    >> so the proper code is:
    >> {{ if $campsite->language->code == "en" }}
    >>
    >> I also made some small optimizations; I removed the local statement which
    >> is not needed and requires a lot of computing resources.
    >>
    >> Mugur
    >>
    >> On Mon, Jun 22, 2009 at 11:45 PM, Generare Management Department <
    >> management@generare.com> wrote:
    >>
    >>> Thanks Mugur!
    >>> We were making like this based on a sample template:
    >>>
    >>> {{ local }}
    >>> {{ set_current_issue }}
    >>> {{ unset_section }}
    >>> {{ if $campsite->language->code = "en" }}
    >>> {{ assign var="ignore_language" value="true" }}
    >>> {{ else }}
    >>> {{ assign var="ignore_language" value="false" }}
    >>> {{ /if }}
    >>> {{ list_articles length="10" constraints="type is Article onsection is on
    >>> onfrontpage is on" ignore_language="$ignore_language" order="bynumber desc"
    >>> }}
    >>> >>> onmouseover="this.style.backgroundColor='#DCF6D2'"
    >>> style="cursor:pointer;cursor: hand;"
    >>> onclick="document.location.href='{{ uri
    >>> options="reset_subtitle_list" }}'"
    >>> onmouseout="this.style.backgroundColor='#ffffff'">
    >>>

    {{ $campsite->article->deck }}


    >>>

    {{ $campsite->article->name }}


    >>> {{ if $campsite->article->teaser_a != "" }}
    >>>

    {{ $campsite->article->teaser_a }}


    >>> {{ /if }}
    >>> {{ if $campsite->article->teaser_b != "" }}
    >>>

    >>> height="5">{{ $campsite->article>teaser_a }}


    >>> {{ /if }}
    >>> {{ if $campsite->image->has_image1 }}
    >>>
    >>> src="/get_img.php?{{ urlparameters options="image 1" }}" border="0">

    >>> {{ /if }}
    >>>

    {{ $campsite->article->intro
    >>> }}


    >>>
    >>>
    >>> {{ /list_articles }}
    >>> {{ /local }}
    >>>
    >>> This is in the template home-middle.tpl that is the main column (2nd) for
    >>> the site layout and the site goes blank on that area and towards right, left
    >>> and top loads fine. So I guess there is some issue of nesting these or maybe
    >>> because setting the languages there... I was just happy thinking
    >>> understanding the templating and then it didn't work out again. Well, I'm
    >>> sure there is a simple way though.
    >>>
    >>> Gene
    >>>
    >>> On 17.6.2009, at 13.27, Mugur Rus wrote:
    >>>
    >>> Use the language data to decide how do you display the articles:
    >>>
    >>> {{ if $campsite->language->code = "en" }}
    >>> {{ assign var="ignore_language" value="true" }}
    >>> {{ else }}
    >>> {{ assign var="ignore_language" value="false" }}
    >>> {{ /if }}
    >>> {{ list_articles ignore_language=`$ignore_language` }}
    >>>
    >>> Hope this helps,
    >>> Mugur
    >>>
    >>> On Mon, Jun 15, 2009 at 10:13 PM, Generare Management Department <
    >>> management@generare.com> wrote:
    >>>
    >>>> Hi!
    >>>>
    >>>> Here we are finetuning the content and the huge amount of languages.
    >>>> Some languages are appearing only with few articles, some are more
    >>>> common.
    >>>>
    >>>> We would like to have the English front page having mixed fresh releases
    >>>> of articles.
    >>>> It is not a problem to do so or look like we understood how to build it
    >>>> but now we get also the same mixed idea if we click on other languages front
    >>>> page. How do I restrict the mixed, fresh releases to appear only with
    >>>> English and the other languages would be pure, only that language
    >>>> translations that is selected to as viewed?
    >>>>
    >>>> I hope you can understand what is the idea.
    >>>>
    >>>> Gene
    >>>>
    >>>
    >>>
    >>>
    >>>
    >>
    >>
    >>
    >>
    >>
    >
    >
    >
    >
  • If you send me a site backup I'll try to debug your problems an help you
    asap.

    Mugur

    On Wed, Jul 29, 2009 at 1:40 PM, Generare Management Department <
    management@generare.com> wrote:

    > Hi!
    > So, to make a short summary:
    >
    > So now it shows in our English page:
    > - correctly ignores the language and shows all the recent articles in any
    > language
    > - incorrectly shows all the translations of the same article as recent
    > articles
    > -> we want to restrict the listing for 1 translation per article
    > (preferring English if it exists)
    >
    >
    > So, I understood from Mugur's answer on 27th of July that it is not
    > practically possible to restrict the output in a way we want:
    >
    > Like this in ENGLISH page:
    >
    > if there is English -> show only English
    > if there is other languages -> show in preferred order only the first one
    > of the list (if Swedish, show that but not for example the French, or if
    > Finnish show that)
    >
    > *
    > *
    > *CONCLUSION:*
    >
    > *-> We keep the English giving all the possible article translations of
    > all fresh releases BUT we ADD a pagination.*
    > *-> For other language we need to restrict to show only those languages
    > that for some reason is not working right now and I do not see anything
    > wrong in the logic that Mugur earlier made for it (template attached)*
    > *
    > *
    > *(-> then we need to still figure the
    > troubles of "the advanced search" what is another thread here)
    > *
    > We are just very late already with the release of the news site here!
    > Campsite is -imho - very powerful but yet so many obstacles has arised along
    > the way that it was not something we could have foreseen even if we have
    > quite a lot of experience on studying new open source systems. So, very
    > potential system but of course it is never happy to find some bugs or
    > stumble in the lack of knowledge how to do something with a new system.
    >
    > Kind regards,
    >
    > Sanna @ Gene
    >
    >
    >
    >
    > On 28.7.2009, at 23.27, Generare Management Department wrote:
    >
    > Is the pagination for listing articles something to do with "currrent
    > list"?It should have been that English language have "mixed" many
    > languages but other languages should have only their own article
    > translations. Now also the other languages get all different versions of the
    > same article listed.
    > Need to focus more on what Mugur sent... maybe I changed something and just
    > can't remember...
    >
    > Sanna
    >
    > On 27.7.2009, at 23.37, Generare Management Department wrote:
    >
    > Yes, I kind of restricted the length for testing purposes to see what
    > comes etc.
    > The real idea would be anyway to have like 10 newest articles on the first
    > page (just boring if they are the same article but different translations
    > but we look that later).
    > The question is now:
    > how do I paginate the articles listing like on the first page 10 newest,
    > then 10 next ones, more 10 etc. until certain amount of total newest (for
    > example 50 newest altogether).
    >
    > I was sure there was something like that in the manual but can't find it or
    > maybe it was something else...
    >
    > /Sanna
    >
    > On 27.7.2009, at 14.03, Mugur Rus wrote:
    >
    > You can restrict any list to any length you want: length="1"
    >
    > {{ list_languages of_article="true" exclude_current="true" length="1" }}
    >
    > If you want English to be used whenever possible use: order="byNumber asc"
    >
    > The English language is the first in the table and has the smallest
    > identifier so it will always be the first. Of course, this way is less than
    > ideal to order languages so we can implement in the future a system of
    > language priority for a certain publication.
    >
    > Mugur
    >
    > On Thu, Jul 23, 2009 at 12:57 PM, Generare Management Department <
    > management@generare.com> wrote:
    >
    >> Hi,
    >> can I restrict the output of listing for one translation per article?
    >> Mugur gave a great idea for the template that we modified for our layout.
    >> But the problem is that we still get like 5 different translations of the
    >> same article when we would need only one (it's quite boring to list the same
    >> article translations and then the list of 10 fits no other articles at all).
    >>
    >> So now it shows in our English page:
    >> - correctly ignores the language and shows all the recent articles in any
    >> language
    >> - incorrectly shows all the translations of the same article as recent
    >> articles
    >> -> we want to restrict the listing for 1 translation per article
    >> (preferring English if it exists)
    >>
    >> Like this:
    >>
    >> if there is English -> show only English
    >> if there is other languages -> show in preferred order only the first one
    >> of the list (if Swedish, show that but not for example the French, or if
    >> Finnish show that)
    >>
    >>
    >> Sanna @ gene
    >>
    >> On 23.6.2009, at 15.38, Generare Management Department wrote:
    >>
    >> Thanks!
    >> I tried the template but it messed our layout. No worries, I combined the
    >> good parts and now it works. Smile
    >> Although now it shows of course in English all the possible translations
    >> of the article (I did ask so, no worry), but could we make in a way that...
    >>
    >> if there is English -> show only English
    >> if there is other languages -> show in preferred order only the first one
    >> of the list (if Swedish, show that but not for example the French, or if
    >> Finnish show that)
    >>
    >> Because when we go to the articles itself, then we have flags that we can
    >> switch the same article in different languages that is available for it.
    >>
    >> Gene
    >>
    >> On 23.6.2009, at 12.53, Mugur Rus wrote:
    >>
    >> Please use the attached template; the comparison is made using ==, not =
    >> so the proper code is:
    >> {{ if $campsite->language->code == "en" }}
    >>
    >> I also made some small optimizations; I removed the local statement which
    >> is not needed and requires a lot of computing resources.
    >>
    >> Mugur
    >>
    >> On Mon, Jun 22, 2009 at 11:45 PM, Generare Management Department <
    >> management@generare.com> wrote:
    >>
    >>> Thanks Mugur!
    >>> We were making like this based on a sample template:
    >>>
    >>> {{ local }}
    >>> {{ set_current_issue }}
    >>> {{ unset_section }}
    >>> {{ if $campsite->language->code = "en" }}
    >>> {{ assign var="ignore_language" value="true" }}
    >>> {{ else }}
    >>> {{ assign var="ignore_language" value="false" }}
    >>> {{ /if }}
    >>> {{ list_articles length="10" constraints="type is Article onsection is on
    >>> onfrontpage is on" ignore_language="$ignore_language" order="bynumber desc"
    >>> }}
    >>> >>> onmouseover="this.style.backgroundColor='#DCF6D2'"
    >>> style="cursor:pointer;cursor: hand;"
    >>> onclick="document.location.href='{{ uri
    >>> options="reset_subtitle_list" }}'"
    >>> onmouseout="this.style.backgroundColor='#ffffff'">
    >>>

    {{ $campsite->article->deck }}


    >>>

    {{ $campsite->article->name }}


    >>> {{ if $campsite->article->teaser_a != "" }}
    >>>

    {{ $campsite->article->teaser_a }}


    >>> {{ /if }}
    >>> {{ if $campsite->article->teaser_b != "" }}
    >>>

    >>> height="5">{{ $campsite->article>teaser_a }}


    >>> {{ /if }}
    >>> {{ if $campsite->image->has_image1 }}
    >>>
    >>> src="/get_img.php?{{ urlparameters options="image 1" }}" border="0">

    >>> {{ /if }}
    >>>

    {{ $campsite->article->intro
    >>> }}


    >>>
    >>>
    >>> {{ /list_articles }}
    >>> {{ /local }}
    >>>
    >>> This is in the template home-middle.tpl that is the main column (2nd) for
    >>> the site layout and the site goes blank on that area and towards right, left
    >>> and top loads fine. So I guess there is some issue of nesting these or maybe
    >>> because setting the languages there... I was just happy thinking
    >>> understanding the templating and then it didn't work out again. Well, I'm
    >>> sure there is a simple way though.
    >>>
    >>> Gene
    >>>
    >>> On 17.6.2009, at 13.27, Mugur Rus wrote:
    >>>
    >>> Use the language data to decide how do you display the articles:
    >>>
    >>> {{ if $campsite->language->code = "en" }}
    >>> {{ assign var="ignore_language" value="true" }}
    >>> {{ else }}
    >>> {{ assign var="ignore_language" value="false" }}
    >>> {{ /if }}
    >>> {{ list_articles ignore_language=`$ignore_language` }}
    >>>
    >>> Hope this helps,
    >>> Mugur
    >>>
    >>> On Mon, Jun 15, 2009 at 10:13 PM, Generare Management Department <
    >>> management@generare.com> wrote:
    >>>
    >>>> Hi!
    >>>>
    >>>> Here we are finetuning the content and the huge amount of languages.
    >>>> Some languages are appearing only with few articles, some are more
    >>>> common.
    >>>>
    >>>> We would like to have the English front page having mixed fresh releases
    >>>> of articles.
    >>>> It is not a problem to do so or look like we understood how to build it
    >>>> but now we get also the same mixed idea if we click on other languages front
    >>>> page. How do I restrict the mixed, fresh releases to appear only with
    >>>> English and the other languages would be pure, only that language
    >>>> translations that is selected to as viewed?
    >>>>
    >>>> I hope you can understand what is the idea.
    >>>>
    >>>> Gene
    >>>>
    >>>
    >>>
    >>>
    >>>
    >>
    >>
    >>
    >>
    >>
    >
    >
    >
    >
  • Yes,

    we want to display the latest news BUT...

    - the default language for the site is ENGLISH and there we want to
    appear all articles that are fresh, no matter which language it is
    (but preference would have been English if it exists and not the others)

    - when we click a flag (that we have put in the layout) and change the
    language from English to for example Swedish, we want all the fresh
    articles but ONLY in that translation of Swedish

    It could be that the explanation is not clear but I could draw an
    example or something...

    /Sanna

    On 29.7.2009, at 13.56, Mugur Rus wrote:

    > The problem here may be some miscommunication; you said you wanted
    > to display the latest news; OK, use list_articles, order them by the
    > publish date and there you have them. But do not use the
    > ignore_language parameter. This, of course, will list all article
    > translations. I remember I said in a previous email, you need to
    > list translations for each article in the list like this:
    >
    > {{ list_articles order="byPublishDate desc" }}
    > display the article in the current language
    > {{ list_languages of_article="true" exclude_current="true" }}
    > display the article translation
    > {{ /list_languages }}
    > {{ /list_articles }}
    >
    > This way you get a list of the latest articles in the current
    > language and their translations. Right now Campsite can't produce a
    > list of articles from different languages and have only one
    > translation of each article in the list.
    >
    > Mugur
    >
    > On Wed, Jul 29, 2009 at 1:40 PM, Generare Management Department > > wrote:
    > Hi!
    >
    > So, to make a short summary:
    >
    >
    >> So now it shows in our English page:
    >> - correctly ignores the language and shows all the recent articles
    >> in any language
    >> - incorrectly shows all the translations of the same article as
    >> recent articles
    >> -> we want to restrict the listing for 1 translation per article
    >> (preferring English if it exists)
    >
    > So, I understood from Mugur's answer on 27th of July that it is not
    > practically possible to restrict the output in a way we want:
    >
    >> Like this in ENGLISH page:
    >>
    >> if there is English -> show only English
    >> if there is other languages -> show in preferred order only the
    >> first one of the list (if Swedish, show that but not for example
    >> the French, or if Finnish show that)
    >
    > CONCLUSION:
    >
    > -> We keep the English giving all the possible article translations
    > of all fresh releases BUT we ADD a pagination.
    > -> For other language we need to restrict to show only those
    > languages that for some reason is not working right now and I do not
    > see anything wrong in the logic that Mugur earlier made for it
    > (template attached)
    >
    > (-> then we need to still figure the troubles of "the advanced
    > search" what is another thread here)
    >
    > We are just very late already with the release of the news site
    > here! Campsite is -imho - very powerful but yet so many obstacles
    > has arised along the way that it was not something we could have
    > foreseen even if we have quite a lot of experience on studying new
    > open source systems. So, very potential system but of course it is
    > never happy to find some bugs or stumble in the lack of knowledge
    > how to do something with a new system.
    >
    > Kind regards,
    >
    > Sanna @ Gene
    >
    >
    >
    >
    > On 28.7.2009, at 23.27, Generare Management Department wrote:
    >
    >> Is the pagination for listing articles something to do with
    >> "currrent list"?
    >> It should have been that English language have "mixed" many
    >> languages but other languages should have only their own article
    >> translations. Now also the other languages get all different
    >> versions of the same article listed.
    >> Need to focus more on what Mugur sent... maybe I changed something
    >> and just can't remember...
    >>
    >> Sanna
    >>
    >> On 27.7.2009, at 23.37, Generare Management Department wrote:
    >>
    >>> Yes,
    >>> I kind of restricted the length for testing purposes to see what
    >>> comes etc.
    >>> The real idea would be anyway to have like 10 newest articles on
    >>> the first page (just boring if they are the same article but
    >>> different translations but we look that later).
    >>> The question is now:
    >>> how do I paginate the articles listing like on the first page 10
    >>> newest, then 10 next ones, more 10 etc. until certain amount of
    >>> total newest (for example 50 newest altogether).
    >>>
    >>> I was sure there was something like that in the manual but can't
    >>> find it or maybe it was something else...
    >>>
    >>> /Sanna
    >>>
    >>> On 27.7.2009, at 14.03, Mugur Rus wrote:
    >>>
    >>>> You can restrict any list to any length you want: length="1"
    >>>>
    >>>> {{ list_languages of_article="true" exclude_current="true"
    >>>> length="1" }}
    >>>>
    >>>> If you want English to be used whenever possible use:
    >>>> order="byNumber asc"
    >>>>
    >>>> The English language is the first in the table and has the
    >>>> smallest identifier so it will always be the first. Of course,
    >>>> this way is less than ideal to order languages so we can
    >>>> implement in the future a system of language priority for a
    >>>> certain publication.
    >>>>
    >>>> Mugur
    >>>>
    >>>> On Thu, Jul 23, 2009 at 12:57 PM, Generare Management Department >>>> > wrote:
    >>>> Hi,
    >>>>
    >>>> can I restrict the output of listing for one translation per
    >>>> article?
    >>>> Mugur gave a great idea for the template that we modified for our
    >>>> layout.
    >>>> But the problem is that we still get like 5 different
    >>>> translations of the same article when we would need only one
    >>>> (it's quite boring to list the same article translations and then
    >>>> the list of 10 fits no other articles at all).
    >>>>
    >>>> So now it shows in our English page:
    >>>> - correctly ignores the language and shows all the recent
    >>>> articles in any language
    >>>> - incorrectly shows all the translations of the same article as
    >>>> recent articles
    >>>> -> we want to restrict the listing for 1 translation per article
    >>>> (preferring English if it exists)
    >>>>
    >>>> Like this:
    >>>>
    >>>>> if there is English -> show only English
    >>>>> if there is other languages -> show in preferred order only the
    >>>>> first one of the list (if Swedish, show that but not for example
    >>>>> the French, or if Finnish show that)
    >>>>
    >>>> Sanna @ gene
    >>>>
    >>>> On 23.6.2009, at 15.38, Generare Management Department wrote:
    >>>>
    >>>>> Thanks!
    >>>>>
    >>>>> I tried the template but it messed our layout. No worries, I
    >>>>> combined the good parts and now it works. Smile
    >>>>> Although now it shows of course in English all the possible
    >>>>> translations of the article (I did ask so, no worry), but could
    >>>>> we make in a way that...
    >>>>>
    >>>>> if there is English -> show only English
    >>>>> if there is other languages -> show in preferred order only the
    >>>>> first one of the list (if Swedish, show that but not for example
    >>>>> the French, or if Finnish show that)
    >>>>>
    >>>>> Because when we go to the articles itself, then we have flags
    >>>>> that we can switch the same article in different languages that
    >>>>> is available for it.
    >>>>>
    >>>>> Gene
    >>>>>
    >>>>> On 23.6.2009, at 12.53, Mugur Rus wrote:
    >>>>>
    >>>>>> Please use the attached template; the comparison is made using
    >>>>>> ==, not = so the proper code is:
    >>>>>> {{ if $campsite->language->code == "en" }}
    >>>>>>
    >>>>>> I also made some small optimizations; I removed the local
    >>>>>> statement which is not needed and requires a lot of computing
    >>>>>> resources.
    >>>>>>
    >>>>>> Mugur
    >>>>>>
    >>>>>> On Mon, Jun 22, 2009 at 11:45 PM, Generare Management
    >>>>>> Department wrote:
    >>>>>> Thanks Mugur!
    >>>>>>
    >>>>>> We were making like this based on a sample template:
    >>>>>>
    >>>>>> {{ local }}
    >>>>>> {{ set_current_issue }}
    >>>>>> {{ unset_section }}
    >>>>>> {{ if $campsite->language->code = "en" }}
    >>>>>> {{ assign var="ignore_language" value="true" }}
    >>>>>> {{ else }}
    >>>>>> {{ assign var="ignore_language" value="false" }}
    >>>>>> {{ /if }}
    >>>>>> {{ list_articles length="10" constraints="type is Article
    >>>>>> onsection is on onfrontpage is on"
    >>>>>> ignore_language="$ignore_language" order="bynumber desc" }}
    >>>>>> >>>>>> onmouseover="this.style.backgroundColor='#DCF6D2'"
    >>>>>> style="cursor:pointer;cursor: hand;"
    >>>>>> onclick="document.location.href='{{ uri
    >>>>>> options="reset_subtitle_list" }}'"
    >>>>>>
    >>>>>> onmouseout="this.style.backgroundColor='#ffffff'">
    >>>>>>

    {{ $campsite->article->deck }}


    >>>>>>

    {{ $campsite->article->name }}


    >>>>>> {{ if $campsite->article->teaser_a != "" }}
    >>>>>>

    {{ $campsite->article-
    >>>>>> >teaser_a }}


    >>>>>> {{ /if }}
    >>>>>> {{ if $campsite->article->teaser_b != "" }}
    >>>>>>

    >>>>>> width="8" height="5">{{ $campsite->article>teaser_a }}


    >>>>>> {{ /if }}
    >>>>>> {{ if $campsite->image->has_image1 }}
    >>>>>>
    >>>>>> div>
    >>>>>> {{ /if }}
    >>>>>>

    {{ $campsite->article-
    >>>>>> >intro }}


    >>>>>>
    >>>>>>
    >>>>>> {{ /list_articles }}
    >>>>>> {{ /local }}
    >>>>>>
    >>>>>> This is in the template home-middle.tpl that is the main column
    >>>>>> (2nd) for the site layout and the site goes blank on that area
    >>>>>> and towards right, left and top loads fine. So I guess there is
    >>>>>> some issue of nesting these or maybe because setting the
    >>>>>> languages there... I was just happy thinking understanding the
    >>>>>> templating and then it didn't work out again. Well, I'm sure
    >>>>>> there is a simple way though.
    >>>>>>
    >>>>>> Gene
    >>>>>>
    >>>>>> On 17.6.2009, at 13.27, Mugur Rus wrote:
    >>>>>>
    >>>>>>> Use the language data to decide how do you display the articles:
    >>>>>>>
    >>>>>>> {{ if $campsite->language->code = "en" }}
    >>>>>>> {{ assign var="ignore_language" value="true" }}
    >>>>>>> {{ else }}
    >>>>>>> {{ assign var="ignore_language" value="false" }}
    >>>>>>> {{ /if }}
    >>>>>>> {{ list_articles ignore_language=`$ignore_language` }}
    >>>>>>>
    >>>>>>> Hope this helps,
    >>>>>>> Mugur
    >>>>>>>
    >>>>>>> On Mon, Jun 15, 2009 at 10:13 PM, Generare Management
    >>>>>>> Department wrote:
    >>>>>>> Hi!
    >>>>>>>
    >>>>>>> Here we are finetuning the content and the huge amount of
    >>>>>>> languages.
    >>>>>>> Some languages are appearing only with few articles, some are
    >>>>>>> more common.
    >>>>>>>
    >>>>>>> We would like to have the English front page having mixed
    >>>>>>> fresh releases of articles.
    >>>>>>> It is not a problem to do so or look like we understood how to
    >>>>>>> build it but now we get also the same mixed idea if we click
    >>>>>>> on other languages front page. How do I restrict the mixed,
    >>>>>>> fresh releases to appear only with English and the other
    >>>>>>> languages would be pure, only that language translations that
    >>>>>>> is selected to as viewed?
    >>>>>>>
    >>>>>>> I hope you can understand what is the idea.
    >>>>>>>
    >>>>>>> Gene
    >>>>>>>
    >>>>>>
    >>>>>>
    >>>>>>
    >>>>>>
    >>>>>>
    >>>>>
    >>>>>
    >>>>
    >>>>
    >
    >
  • Hi Sanna,

    The first option is not doable right now; you can have all English articles,
    but not a mix of English and other languages without having also duplicates
    of the same article in different languages.

    Mugur

    On Wed, Jul 29, 2009 at 2:04 PM, Generare Management Department <
    management@generare.com> wrote:

    > Yes,
    > we want to display the latest news BUT...
    >
    > - the default language for the site is ENGLISH and there we want to appear
    > all articles that are fresh, no matter which language it is (but preference
    > would have been English if it exists and not the others)
    >
    > - when we click a flag (that we have put in the layout) and change the
    > language from English to for example Swedish, we want all the fresh articles
    > but ONLY in that translation of Swedish
    >
    > It could be that the explanation is not clear but I could draw an example
    > or something...
    >
    > /Sanna
    >
    > On 29.7.2009, at 13.56, Mugur Rus wrote:
    >
    > The problem here may be some miscommunication; you said you wanted to
    > display the latest news; OK, use list_articles, order them by the publish
    > date and there you have them. But do not use the ignore_language parameter.
    > This, of course, will list all article translations. I remember I said in a
    > previous email, you need to list translations for each article in the list
    > like this:
    >
    > {{ list_articles order="byPublishDate desc" }}
    > display the article in the current language
    > {{ list_languages of_article="true" exclude_current="true" }}
    > display the article translation
    > {{ /list_languages }}
    > {{ /list_articles }}
    >
    > This way you get a list of the latest articles in the current language and
    > their translations. Right now Campsite can't produce a list of articles from
    > different languages and have only one translation of each article in the
    > list.
    >
    > Mugur
    >
    > On Wed, Jul 29, 2009 at 1:40 PM, Generare Management Department <
    > management@generare.com> wrote:
    >
    >> Hi!
    >> So, to make a short summary:
    >>
    >> So now it shows in our English page:
    >> - correctly ignores the language and shows all the recent articles in any
    >> language
    >> - incorrectly shows all the translations of the same article as recent
    >> articles
    >> -> we want to restrict the listing for 1 translation per article
    >> (preferring English if it exists)
    >>
    >>
    >> So, I understood from Mugur's answer on 27th of July that it is not
    >> practically possible to restrict the output in a way we want:
    >>
    >> Like this in ENGLISH page:
    >>
    >> if there is English -> show only English
    >> if there is other languages -> show in preferred order only the first one
    >> of the list (if Swedish, show that but not for example the French, or if
    >> Finnish show that)
    >>
    >> *
    >> *
    >> *CONCLUSION:*
    >>
    >> *-> We keep the English giving all the possible article translations of
    >> all fresh releases BUT we ADD a pagination.*
    >> *-> For other language we need to restrict to show only those languages
    >> that for some reason is not working right now and I do not see anything
    >> wrong in the logic that Mugur earlier made for it (template attached)*
    >> *
    >> *
    >> *(-> then we need to still figure the
    >> troubles of "the advanced search" what is another thread here)
    >> *
    >> We are just very late already with the release of the news site here!
    >> Campsite is -imho - very powerful but yet so many obstacles has arised along
    >> the way that it was not something we could have foreseen even if we have
    >> quite a lot of experience on studying new open source systems. So, very
    >> potential system but of course it is never happy to find some bugs or
    >> stumble in the lack of knowledge how to do something with a new system.
    >>
    >> Kind regards,
    >>
    >> Sanna @ Gene
    >>
    >>
    >>
    >>
    >> On 28.7.2009, at 23.27, Generare Management Department wrote:
    >>
    >> Is the pagination for listing articles something to do with "currrent
    >> list"? It should have been that English language have "mixed" many
    >> languages but other languages should have only their own article
    >> translations. Now also the other languages get all different versions of the
    >> same article listed.
    >> Need to focus more on what Mugur sent... maybe I changed something and
    >> just can't remember...
    >>
    >> Sanna
    >>
    >> On 27.7.2009, at 23.37, Generare Management Department wrote:
    >>
    >> Yes, I kind of restricted the length for testing purposes to see what
    >> comes etc.
    >> The real idea would be anyway to have like 10 newest articles on the first
    >> page (just boring if they are the same article but different translations
    >> but we look that later).
    >> The question is now:
    >> how do I paginate the articles listing like on the first page 10 newest,
    >> then 10 next ones, more 10 etc. until certain amount of total newest (for
    >> example 50 newest altogether).
    >>
    >> I was sure there was something like that in the manual but can't find it
    >> or maybe it was something else...
    >>
    >> /Sanna
    >>
    >> On 27.7.2009, at 14.03, Mugur Rus wrote:
    >>
    >> You can restrict any list to any length you want: length="1"
    >>
    >> {{ list_languages of_article="true" exclude_current="true" length="1" }}
    >>
    >> If you want English to be used whenever possible use: order="byNumber asc"
    >>
    >> The English language is the first in the table and has the smallest
    >> identifier so it will always be the first. Of course, this way is less than
    >> ideal to order languages so we can implement in the future a system of
    >> language priority for a certain publication.
    >>
    >> Mugur
    >>
    >> On Thu, Jul 23, 2009 at 12:57 PM, Generare Management Department <
    >> management@generare.com> wrote:
    >>
    >>> Hi,
    >>> can I restrict the output of listing for one translation per article?
    >>> Mugur gave a great idea for the template that we modified for our layout.
    >>> But the problem is that we still get like 5 different translations of the
    >>> same article when we would need only one (it's quite boring to list the same
    >>> article translations and then the list of 10 fits no other articles at all).
    >>>
    >>> So now it shows in our English page:
    >>> - correctly ignores the language and shows all the recent articles in any
    >>> language
    >>> - incorrectly shows all the translations of the same article as recent
    >>> articles
    >>> -> we want to restrict the listing for 1 translation per article
    >>> (preferring English if it exists)
    >>>
    >>> Like this:
    >>>
    >>> if there is English -> show only English
    >>> if there is other languages -> show in preferred order only the first one
    >>> of the list (if Swedish, show that but not for example the French, or if
    >>> Finnish show that)
    >>>
    >>>
    >>> Sanna @ gene
    >>>
    >>> On 23.6.2009, at 15.38, Generare Management Department wrote:
    >>>
    >>> Thanks!
    >>> I tried the template but it messed our layout. No worries, I combined the
    >>> good parts and now it works. Smile
    >>> Although now it shows of course in English all the possible translations
    >>> of the article (I did ask so, no worry), but could we make in a way that...
    >>>
    >>> if there is English -> show only English
    >>> if there is other languages -> show in preferred order only the first one
    >>> of the list (if Swedish, show that but not for example the French, or if
    >>> Finnish show that)
    >>>
    >>> Because when we go to the articles itself, then we have flags that we can
    >>> switch the same article in different languages that is available for it.
    >>>
    >>> Gene
    >>>
    >>> On 23.6.2009, at 12.53, Mugur Rus wrote:
    >>>
    >>> Please use the attached template; the comparison is made using ==, not =
    >>> so the proper code is:
    >>> {{ if $campsite->language->code == "en" }}
    >>>
    >>> I also made some small optimizations; I removed the local statement which
    >>> is not needed and requires a lot of computing resources.
    >>>
    >>> Mugur
    >>>
    >>> On Mon, Jun 22, 2009 at 11:45 PM, Generare Management Department <
    >>> management@generare.com> wrote:
    >>>
    >>>> Thanks Mugur!
    >>>> We were making like this based on a sample template:
    >>>>
    >>>> {{ local }}
    >>>> {{ set_current_issue }}
    >>>> {{ unset_section }}
    >>>> {{ if $campsite->language->code = "en" }}
    >>>> {{ assign var="ignore_language" value="true" }}
    >>>> {{ else }}
    >>>> {{ assign var="ignore_language" value="false" }}
    >>>> {{ /if }}
    >>>> {{ list_articles length="10" constraints="type is Article onsection is
    >>>> on onfrontpage is on" ignore_language="$ignore_language" order="bynumber
    >>>> desc" }}
    >>>> >>>> onmouseover="this.style.backgroundColor='#DCF6D2'"
    >>>> style="cursor:pointer;cursor: hand;"
    >>>> onclick="document.location.href='{{ uri
    >>>> options="reset_subtitle_list" }}'"
    >>>>
    >>>> onmouseout="this.style.backgroundColor='#ffffff'">
    >>>>

    {{ $campsite->article->deck }}


    >>>>

    {{ $campsite->article->name }}


    >>>> {{ if $campsite->article->teaser_a != "" }}
    >>>>

    {{ $campsite->article->teaser_a }}


    >>>> {{ /if }}
    >>>> {{ if $campsite->article->teaser_b != "" }}
    >>>>

    >>>> height="5">{{ $campsite->article>teaser_a }}


    >>>> {{ /if }}
    >>>> {{ if $campsite->image->has_image1 }}
    >>>>
    >>>> src="/get_img.php?{{ urlparameters options="image 1" }}" border="0">

    >>>> {{ /if }}
    >>>>

    {{ $campsite->article->intro
    >>>> }}


    >>>>
    >>>>
    >>>> {{ /list_articles }}
    >>>> {{ /local }}
    >>>>
    >>>> This is in the template home-middle.tpl that is the main column (2nd)
    >>>> for the site layout and the site goes blank on that area and towards right,
    >>>> left and top loads fine. So I guess there is some issue of nesting these or
    >>>> maybe because setting the languages there... I was just happy thinking
    >>>> understanding the templating and then it didn't work out again. Well, I'm
    >>>> sure there is a simple way though.
    >>>>
    >>>> Gene
    >>>>
    >>>> On 17.6.2009, at 13.27, Mugur Rus wrote:
    >>>>
    >>>> Use the language data to decide how do you display the articles:
    >>>>
    >>>> {{ if $campsite->language->code = "en" }}
    >>>> {{ assign var="ignore_language" value="true" }}
    >>>> {{ else }}
    >>>> {{ assign var="ignore_language" value="false" }}
    >>>> {{ /if }}
    >>>> {{ list_articles ignore_language=`$ignore_language` }}
    >>>>
    >>>> Hope this helps,
    >>>> Mugur
    >>>>
    >>>> On Mon, Jun 15, 2009 at 10:13 PM, Generare Management Department <
    >>>> management@generare.com> wrote:
    >>>>
    >>>>> Hi!
    >>>>>
    >>>>> Here we are finetuning the content and the huge amount of languages.
    >>>>> Some languages are appearing only with few articles, some are more
    >>>>> common.
    >>>>>
    >>>>> We would like to have the English front page having mixed fresh
    >>>>> releases of articles.
    >>>>> It is not a problem to do so or look like we understood how to build it
    >>>>> but now we get also the same mixed idea if we click on other languages front
    >>>>> page. How do I restrict the mixed, fresh releases to appear only with
    >>>>> English and the other languages would be pure, only that language
    >>>>> translations that is selected to as viewed?
    >>>>>
    >>>>> I hope you can understand what is the idea.
    >>>>>
    >>>>> Gene
    >>>>>
    >>>>
    >>>>
    >>>>
    >>>>
    >>>
    >>>
    >>>
    >>>
    >>>
    >>
    >
    >
    >
  • Yes, I got that Smile

    So we make mix of English and others in English page (just need the
    pagination for that)
    and
    clean languages when getting the other languages pages
    (I'm just not getting why it doesn't already work so, but didn't work
    with the local test either)

    Sanna

    P.S. Sending you the db pack soon for the general issue

    On 29.7.2009, at 14.35, Mugur Rus wrote:

    > Hi Sanna,
    >
    > The first option is not doable right now; you can have all English
    > articles, but not a mix of English and other languages without
    > having also duplicates of the same article in different languages.
    >
    > Mugur
    >
    > On Wed, Jul 29, 2009 at 2:04 PM, Generare Management Department > > wrote:
    > Yes,
    >
    > we want to display the latest news BUT...
    >
    > - the default language for the site is ENGLISH and there we want to
    > appear all articles that are fresh, no matter which language it is
    > (but preference would have been English if it exists and not the
    > others)
    >
    > - when we click a flag (that we have put in the layout) and change
    > the language from English to for example Swedish, we want all the
    > fresh articles but ONLY in that translation of Swedish
    >
    > It could be that the explanation is not clear but I could draw an
    > example or something...
    >
    > /Sanna
    >
    > On 29.7.2009, at 13.56, Mugur Rus wrote:
    >
    >> The problem here may be some miscommunication; you said you wanted
    >> to display the latest news; OK, use list_articles, order them by
    >> the publish date and there you have them. But do not use the
    >> ignore_language parameter. This, of course, will list all article
    >> translations. I remember I said in a previous email, you need to
    >> list translations for each article in the list like this:
    >>
    >> {{ list_articles order="byPublishDate desc" }}
    >> display the article in the current language
    >> {{ list_languages of_article="true" exclude_current="true" }}
    >> display the article translation
    >> {{ /list_languages }}
    >> {{ /list_articles }}
    >>
    >> This way you get a list of the latest articles in the current
    >> language and their translations. Right now Campsite can't produce a
    >> list of articles from different languages and have only one
    >> translation of each article in the list.
    >>
    >> Mugur
    >>
    >> On Wed, Jul 29, 2009 at 1:40 PM, Generare Management Department >> > wrote:
    >> Hi!
    >>
    >> So, to make a short summary:
    >>
    >>
    >>> So now it shows in our English page:
    >>> - correctly ignores the language and shows all the recent articles
    >>> in any language
    >>> - incorrectly shows all the translations of the same article as
    >>> recent articles
    >>> -> we want to restrict the listing for 1 translation per article
    >>> (preferring English if it exists)
    >>
    >> So, I understood from Mugur's answer on 27th of July that it is not
    >> practically possible to restrict the output in a way we want:
    >>
    >>> Like this in ENGLISH page:
    >>>
    >>> if there is English -> show only English
    >>> if there is other languages -> show in preferred order only the
    >>> first one of the list (if Swedish, show that but not for example
    >>> the French, or if Finnish show that)
    >>
    >> CONCLUSION:
    >>
    >> -> We keep the English giving all the possible article translations
    >> of all fresh releases BUT we ADD a pagination.
    >> -> For other language we need to restrict to show only those
    >> languages that for some reason is not working right now and I do
    >> not see anything wrong in the logic that Mugur earlier made for it
    >> (template attached)
    >>
    >> (-> then we need to still figure the troubles of "the advanced
    >> search" what is another thread here)
    >>
    >> We are just very late already with the release of the news site
    >> here! Campsite is -imho - very powerful but yet so many obstacles
    >> has arised along the way that it was not something we could have
    >> foreseen even if we have quite a lot of experience on studying new
    >> open source systems. So, very potential system but of course it is
    >> never happy to find some bugs or stumble in the lack of knowledge
    >> how to do something with a new system.
    >>
    >> Kind regards,
    >>
    >> Sanna @ Gene
    >>
    >>
    >>
    >>
    >> On 28.7.2009, at 23.27, Generare Management Department wrote:
    >>
    >>> Is the pagination for listing articles something to do with
    >>> "currrent list"?
    >>> It should have been that English language have "mixed" many
    >>> languages but other languages should have only their own article
    >>> translations. Now also the other languages get all different
    >>> versions of the same article listed.
    >>> Need to focus more on what Mugur sent... maybe I changed something
    >>> and just can't remember...
    >>>
    >>> Sanna
    >>>
    >>> On 27.7.2009, at 23.37, Generare Management Department wrote:
    >>>
    >>>> Yes,
    >>>> I kind of restricted the length for testing purposes to see what
    >>>> comes etc.
    >>>> The real idea would be anyway to have like 10 newest articles on
    >>>> the first page (just boring if they are the same article but
    >>>> different translations but we look that later).
    >>>> The question is now:
    >>>> how do I paginate the articles listing like on the first page 10
    >>>> newest, then 10 next ones, more 10 etc. until certain amount of
    >>>> total newest (for example 50 newest altogether).
    >>>>
    >>>> I was sure there was something like that in the manual but can't
    >>>> find it or maybe it was something else...
    >>>>
    >>>> /Sanna
    >>>>
    >>>> On 27.7.2009, at 14.03, Mugur Rus wrote:
    >>>>
    >>>>> You can restrict any list to any length you want: length="1"
    >>>>>
    >>>>> {{ list_languages of_article="true" exclude_current="true"
    >>>>> length="1" }}
    >>>>>
    >>>>> If you want English to be used whenever possible use:
    >>>>> order="byNumber asc"
    >>>>>
    >>>>> The English language is the first in the table and has the
    >>>>> smallest identifier so it will always be the first. Of course,
    >>>>> this way is less than ideal to order languages so we can
    >>>>> implement in the future a system of language priority for a
    >>>>> certain publication.
    >>>>>
    >>>>> Mugur
    >>>>>
    >>>>> On Thu, Jul 23, 2009 at 12:57 PM, Generare Management Department
    >>>>> wrote:
    >>>>> Hi,
    >>>>>
    >>>>> can I restrict the output of listing for one translation per
    >>>>> article?
    >>>>> Mugur gave a great idea for the template that we modified for
    >>>>> our layout.
    >>>>> But the problem is that we still get like 5 different
    >>>>> translations of the same article when we would need only one
    >>>>> (it's quite boring to list the same article translations and
    >>>>> then the list of 10 fits no other articles at all).
    >>>>>
    >>>>> So now it shows in our English page:
    >>>>> - correctly ignores the language and shows all the recent
    >>>>> articles in any language
    >>>>> - incorrectly shows all the translations of the same article as
    >>>>> recent articles
    >>>>> -> we want to restrict the listing for 1 translation per article
    >>>>> (preferring English if it exists)
    >>>>>
    >>>>> Like this:
    >>>>>
    >>>>>> if there is English -> show only English
    >>>>>> if there is other languages -> show in preferred order only the
    >>>>>> first one of the list (if Swedish, show that but not for
    >>>>>> example the French, or if Finnish show that)
    >>>>>
    >>>>> Sanna @ gene
    >>>>>
    >>>>> On 23.6.2009, at 15.38, Generare Management Department wrote:
    >>>>>
    >>>>>> Thanks!
    >>>>>>
    >>>>>> I tried the template but it messed our layout. No worries, I
    >>>>>> combined the good parts and now it works. Smile
    >>>>>> Although now it shows of course in English all the possible
    >>>>>> translations of the article (I did ask so, no worry), but could
    >>>>>> we make in a way that...
    >>>>>>
    >>>>>> if there is English -> show only English
    >>>>>> if there is other languages -> show in preferred order only the
    >>>>>> first one of the list (if Swedish, show that but not for
    >>>>>> example the French, or if Finnish show that)
    >>>>>>
    >>>>>> Because when we go to the articles itself, then we have flags
    >>>>>> that we can switch the same article in different languages that
    >>>>>> is available for it.
    >>>>>>
    >>>>>> Gene
    >>>>>>
    >>>>>> On 23.6.2009, at 12.53, Mugur Rus wrote:
    >>>>>>
    >>>>>>> Please use the attached template; the comparison is made using
    >>>>>>> ==, not = so the proper code is:
    >>>>>>> {{ if $campsite->language->code == "en" }}
    >>>>>>>
    >>>>>>> I also made some small optimizations; I removed the local
    >>>>>>> statement which is not needed and requires a lot of computing
    >>>>>>> resources.
    >>>>>>>
    >>>>>>> Mugur
    >>>>>>>
    >>>>>>> On Mon, Jun 22, 2009 at 11:45 PM, Generare Management
    >>>>>>> Department wrote:
    >>>>>>> Thanks Mugur!
    >>>>>>>
    >>>>>>> We were making like this based on a sample template:
    >>>>>>>
    >>>>>>> {{ local }}
    >>>>>>> {{ set_current_issue }}
    >>>>>>> {{ unset_section }}
    >>>>>>> {{ if $campsite->language->code = "en" }}
    >>>>>>> {{ assign var="ignore_language" value="true" }}
    >>>>>>> {{ else }}
    >>>>>>> {{ assign var="ignore_language" value="false" }}
    >>>>>>> {{ /if }}
    >>>>>>> {{ list_articles length="10" constraints="type is Article
    >>>>>>> onsection is on onfrontpage is on"
    >>>>>>> ignore_language="$ignore_language" order="bynumber desc" }}
    >>>>>>> >>>>>>> onmouseover="this.style.backgroundColor='#DCF6D2'"
    >>>>>>> style="cursor:pointer;cursor: hand;"
    >>>>>>> onclick="document.location.href='{{ uri
    >>>>>>> options="reset_subtitle_list" }}'"
    >>>>>>>
    >>>>>>> onmouseout="this.style.backgroundColor='#ffffff'">
    >>>>>>>

    {{ $campsite->article->deck }}


    >>>>>>>

    {{ $campsite->article->name }}


    >>>>>>> {{ if $campsite->article->teaser_a != "" }}
    >>>>>>>

    {{ $campsite->article-
    >>>>>>> >teaser_a }}


    >>>>>>> {{ /if }}
    >>>>>>> {{ if $campsite->article->teaser_b != "" }}
    >>>>>>>

    >>>>>>> width="8" height="5">{{ $campsite->article>teaser_a }}


    >>>>>>> {{ /if }}
    >>>>>>> {{ if $campsite->image->has_image1 }}
    >>>>>>>
    >>>>>>> border="0">

    >>>>>>> {{ /if }}
    >>>>>>>

    {{ $campsite->article-
    >>>>>>> >intro }}


    >>>>>>>
    >>>>>>>
    >>>>>>> {{ /list_articles }}
    >>>>>>> {{ /local }}
    >>>>>>>
    >>>>>>> This is in the template home-middle.tpl that is the main
    >>>>>>> column (2nd) for the site layout and the site goes blank on
    >>>>>>> that area and towards right, left and top loads fine. So I
    >>>>>>> guess there is some issue of nesting these or maybe because
    >>>>>>> setting the languages there... I was just happy thinking
    >>>>>>> understanding the templating and then it didn't work out
    >>>>>>> again. Well, I'm sure there is a simple way though.
    >>>>>>>
    >>>>>>> Gene
    >>>>>>>
    >>>>>>> On 17.6.2009, at 13.27, Mugur Rus wrote:
    >>>>>>>
    >>>>>>>> Use the language data to decide how do you display the
    >>>>>>>> articles:
    >>>>>>>>
    >>>>>>>> {{ if $campsite->language->code = "en" }}
    >>>>>>>> {{ assign var="ignore_language" value="true" }}
    >>>>>>>> {{ else }}
    >>>>>>>> {{ assign var="ignore_language" value="false" }}
    >>>>>>>> {{ /if }}
    >>>>>>>> {{ list_articles ignore_language=`$ignore_language` }}
    >>>>>>>>
    >>>>>>>> Hope this helps,
    >>>>>>>> Mugur
    >>>>>>>>
    >>>>>>>> On Mon, Jun 15, 2009 at 10:13 PM, Generare Management
    >>>>>>>> Department wrote:
    >>>>>>>> Hi!
    >>>>>>>>
    >>>>>>>> Here we are finetuning the content and the huge amount of
    >>>>>>>> languages.
    >>>>>>>> Some languages are appearing only with few articles, some are
    >>>>>>>> more common.
    >>>>>>>>
    >>>>>>>> We would like to have the English front page having mixed
    >>>>>>>> fresh releases of articles.
    >>>>>>>> It is not a problem to do so or look like we understood how
    >>>>>>>> to build it but now we get also the same mixed idea if we
    >>>>>>>> click on other languages front page. How do I restrict the
    >>>>>>>> mixed, fresh releases to appear only with English and the
    >>>>>>>> other languages would be pure, only that language
    >>>>>>>> translations that is selected to as viewed?
    >>>>>>>>
    >>>>>>>> I hope you can understand what is the idea.
    >>>>>>>>
    >>>>>>>> Gene
    >>>>>>>>
    >>>>>>>
    >>>>>>>
    >>>>>>>
    >>>>>>>
    >>>>>>>
    >>>>>>
    >>>>>>
    >>>>>
    >>>>>
    >>
    >>
  • By the way,

    I have been thinking... when listing articles the variable
    "ignore_language" could get values "true" and "false" and that's how I
    got this idea from Mugur with assigning a value for it by another
    variable, also named "ignore_language". Although used with a $ in the
    real listing code, can it actually have this reserved name of
    "ignore_language"?

    But now when reading the manual again, it doesn't give options for
    values like "true | false", it says only [ignore_language="true"]. So,
    since even with value "false" the site has been ignoring the language,
    could that be the reason why my template didn't work? If the
    ignore_language can be only "true" and not "false", we need to make
    another solution for the logic of IF English ELSE other languages...

    list_articles [length=""] [columns=""]
    [constraints=""]
    [ignore_issue="true"] [ignore_section="true"]
    [ignore_language="true"]

    Thanks for the previous answers as well!

    /Sanna

    On 29.7.2009, at 14.55, Generare Management Department wrote:

    > Yes, I got that Smile
    >
    > So we make mix of English and others in English page (just need the
    > pagination for that)
    > and
    > clean languages when getting the other languages pages
    > (I'm just not getting why it doesn't already work so, but didn't
    > work with the local test either)
    >
    > Sanna
    >
    > P.S. Sending you the db pack soon for the general issue
    >
    > On 29.7.2009, at 14.35, Mugur Rus wrote:
    >
    >> Hi Sanna,
    >>
    >> The first option is not doable right now; you can have all English
    >> articles, but not a mix of English and other languages without
    >> having also duplicates of the same article in different languages.
    >>
    >> Mugur
    >>
    >> On Wed, Jul 29, 2009 at 2:04 PM, Generare Management Department >> > wrote:
    >> Yes,
    >>
    >> we want to display the latest news BUT...
    >>
    >> - the default language for the site is ENGLISH and there we want to
    >> appear all articles that are fresh, no matter which language it is
    >> (but preference would have been English if it exists and not the
    >> others)
    >>
    >> - when we click a flag (that we have put in the layout) and change
    >> the language from English to for example Swedish, we want all the
    >> fresh articles but ONLY in that translation of Swedish
    >>
    >> It could be that the explanation is not clear but I could draw an
    >> example or something...
    >>
    >> /Sanna
    >>
    >> On 29.7.2009, at 13.56, Mugur Rus wrote:
    >>
    >>> The problem here may be some miscommunication; you said you wanted
    >>> to display the latest news; OK, use list_articles, order them by
    >>> the publish date and there you have them. But do not use the
    >>> ignore_language parameter. This, of course, will list all article
    >>> translations. I remember I said in a previous email, you need to
    >>> list translations for each article in the list like this:
    >>>
    >>> {{ list_articles order="byPublishDate desc" }}
    >>> display the article in the current language
    >>> {{ list_languages of_article="true" exclude_current="true" }}
    >>> display the article translation
    >>> {{ /list_languages }}
    >>> {{ /list_articles }}
    >>>
    >>> This way you get a list of the latest articles in the current
    >>> language and their translations. Right now Campsite can't produce
    >>> a list of articles from different languages and have only one
    >>> translation of each article in the list.
    >>>
    >>> Mugur
    >>>
    >>> On Wed, Jul 29, 2009 at 1:40 PM, Generare Management Department >>> > wrote:
    >>> Hi!
    >>>
    >>> So, to make a short summary:
    >>>
    >>>
    >>>> So now it shows in our English page:
    >>>> - correctly ignores the language and shows all the recent
    >>>> articles in any language
    >>>> - incorrectly shows all the translations of the same article as
    >>>> recent articles
    >>>> -> we want to restrict the listing for 1 translation per article
    >>>> (preferring English if it exists)
    >>>
    >>> So, I understood from Mugur's answer on 27th of July that it is
    >>> not practically possible to restrict the output in a way we want:
    >>>
    >>>> Like this in ENGLISH page:
    >>>>
    >>>> if there is English -> show only English
    >>>> if there is other languages -> show in preferred order only the
    >>>> first one of the list (if Swedish, show that but not for example
    >>>> the French, or if Finnish show that)
    >>>
    >>> CONCLUSION:
    >>>
    >>> -> We keep the English giving all the possible article
    >>> translations of all fresh releases BUT we ADD a pagination.
    >>> -> For other language we need to restrict to show only those
    >>> languages that for some reason is not working right now and I do
    >>> not see anything wrong in the logic that Mugur earlier made for it
    >>> (template attached)
    >>>
    >>> (-> then we need to still figure the troubles of "the advanced
    >>> search" what is another thread here)
    >>>
    >>> We are just very late already with the release of the news site
    >>> here! Campsite is -imho - very powerful but yet so many obstacles
    >>> has arised along the way that it was not something we could have
    >>> foreseen even if we have quite a lot of experience on studying new
    >>> open source systems. So, very potential system but of course it is
    >>> never happy to find some bugs or stumble in the lack of knowledge
    >>> how to do something with a new system.
    >>>
    >>> Kind regards,
    >>>
    >>> Sanna @ Gene
    >>>
    >>>
    >>>
    >>>
    >>> On 28.7.2009, at 23.27, Generare Management Department wrote:
    >>>
    >>>> Is the pagination for listing articles something to do with
    >>>> "currrent list"?
    >>>> It should have been that English language have "mixed" many
    >>>> languages but other languages should have only their own article
    >>>> translations. Now also the other languages get all different
    >>>> versions of the same article listed.
    >>>> Need to focus more on what Mugur sent... maybe I changed
    >>>> something and just can't remember...
    >>>>
    >>>> Sanna
    >>>>
    >>>> On 27.7.2009, at 23.37, Generare Management Department wrote:
    >>>>
    >>>>> Yes,
    >>>>> I kind of restricted the length for testing purposes to see what
    >>>>> comes etc.
    >>>>> The real idea would be anyway to have like 10 newest articles on
    >>>>> the first page (just boring if they are the same article but
    >>>>> different translations but we look that later).
    >>>>> The question is now:
    >>>>> how do I paginate the articles listing like on the first page 10
    >>>>> newest, then 10 next ones, more 10 etc. until certain amount of
    >>>>> total newest (for example 50 newest altogether).
    >>>>>
    >>>>> I was sure there was something like that in the manual but can't
    >>>>> find it or maybe it was something else...
    >>>>>
    >>>>> /Sanna
    >>>>>
    >>>>> On 27.7.2009, at 14.03, Mugur Rus wrote:
    >>>>>
    >>>>>> You can restrict any list to any length you want: length="1"
    >>>>>>
    >>>>>> {{ list_languages of_article="true" exclude_current="true"
    >>>>>> length="1" }}
    >>>>>>
    >>>>>> If you want English to be used whenever possible use:
    >>>>>> order="byNumber asc"
    >>>>>>
    >>>>>> The English language is the first in the table and has the
    >>>>>> smallest identifier so it will always be the first. Of course,
    >>>>>> this way is less than ideal to order languages so we can
    >>>>>> implement in the future a system of language priority for a
    >>>>>> certain publication.
    >>>>>>
    >>>>>> Mugur
    >>>>>>
    >>>>>> On Thu, Jul 23, 2009 at 12:57 PM, Generare Management
    >>>>>> Department wrote:
    >>>>>> Hi,
    >>>>>>
    >>>>>> can I restrict the output of listing for one translation per
    >>>>>> article?
    >>>>>> Mugur gave a great idea for the template that we modified for
    >>>>>> our layout.
    >>>>>> But the problem is that we still get like 5 different
    >>>>>> translations of the same article when we would need only one
    >>>>>> (it's quite boring to list the same article translations and
    >>>>>> then the list of 10 fits no other articles at all).
    >>>>>>
    >>>>>> So now it shows in our English page:
    >>>>>> - correctly ignores the language and shows all the recent
    >>>>>> articles in any language
    >>>>>> - incorrectly shows all the translations of the same article as
    >>>>>> recent articles
    >>>>>> -> we want to restrict the listing for 1 translation per
    >>>>>> article (preferring English if it exists)
    >>>>>>
    >>>>>> Like this:
    >>>>>>
    >>>>>>> if there is English -> show only English
    >>>>>>> if there is other languages -> show in preferred order only
    >>>>>>> the first one of the list (if Swedish, show that but not for
    >>>>>>> example the French, or if Finnish show that)
    >>>>>>
    >>>>>> Sanna @ gene
    >>>>>>
    >>>>>> On 23.6.2009, at 15.38, Generare Management Department wrote:
    >>>>>>
    >>>>>>> Thanks!
    >>>>>>>
    >>>>>>> I tried the template but it messed our layout. No worries, I
    >>>>>>> combined the good parts and now it works. Smile
    >>>>>>> Although now it shows of course in English all the possible
    >>>>>>> translations of the article (I did ask so, no worry), but
    >>>>>>> could we make in a way that...
    >>>>>>>
    >>>>>>> if there is English -> show only English
    >>>>>>> if there is other languages -> show in preferred order only
    >>>>>>> the first one of the list (if Swedish, show that but not for
    >>>>>>> example the French, or if Finnish show that)
    >>>>>>>
    >>>>>>> Because when we go to the articles itself, then we have flags
    >>>>>>> that we can switch the same article in different languages
    >>>>>>> that is available for it.
    >>>>>>>
    >>>>>>> Gene
    >>>>>>>
    >>>>>>> On 23.6.2009, at 12.53, Mugur Rus wrote:
    >>>>>>>
    >>>>>>>> Please use the attached template; the comparison is made
    >>>>>>>> using ==, not = so the proper code is:
    >>>>>>>> {{ if $campsite->language->code == "en" }}
    >>>>>>>>
    >>>>>>>> I also made some small optimizations; I removed the local
    >>>>>>>> statement which is not needed and requires a lot of computing
    >>>>>>>> resources.
    >>>>>>>>
    >>>>>>>> Mugur
    >>>>>>>>
    >>>>>>>> On Mon, Jun 22, 2009 at 11:45 PM, Generare Management
    >>>>>>>> Department wrote:
    >>>>>>>> Thanks Mugur!
    >>>>>>>>
    >>>>>>>> We were making like this based on a sample template:
    >>>>>>>>
    >>>>>>>> {{ local }}
    >>>>>>>> {{ set_current_issue }}
    >>>>>>>> {{ unset_section }}
    >>>>>>>> {{ if $campsite->language->code = "en" }}
    >>>>>>>> {{ assign var="ignore_language" value="true" }}
    >>>>>>>> {{ else }}
    >>>>>>>> {{ assign var="ignore_language" value="false" }}
    >>>>>>>> {{ /if }}
    >>>>>>>> {{ list_articles length="10" constraints="type is Article
    >>>>>>>> onsection is on onfrontpage is on"
    >>>>>>>> ignore_language="$ignore_language" order="bynumber desc" }}
    >>>>>>>> >>>>>>>> onmouseover="this.style.backgroundColor='#DCF6D2'"
    >>>>>>>> style="cursor:pointer;cursor: hand;"
    >>>>>>>>
    >>>>>>>> onclick="document.location.href='{{ uri
    >>>>>>>> options="reset_subtitle_list" }}'"
    >>>>>>>>
    >>>>>>>> onmouseout="this.style.backgroundColor='#ffffff'">
    >>>>>>>>

    {{ $campsite->article->deck }}


    >>>>>>>>

    {{ $campsite->article->name }}


    >>>>>>>> {{ if $campsite->article->teaser_a != "" }}
    >>>>>>>>

    {{ $campsite->article-
    >>>>>>>> >teaser_a }}


    >>>>>>>> {{ /if }}
    >>>>>>>> {{ if $campsite->article->teaser_b != "" }}
    >>>>>>>>

    >>>>>>>> width="8" height="5">{{ $campsite->article>teaser_a }}


    >>>>>>>> {{ /if }}
    >>>>>>>> {{ if $campsite->image->has_image1 }}
    >>>>>>>>
    >>>>>>>> border="0">

    >>>>>>>> {{ /if }}
    >>>>>>>>

    {{ $campsite->article-
    >>>>>>>> >intro }}


    >>>>>>>>
    >>>>>>>>
    >>>>>>>> {{ /list_articles }}
    >>>>>>>> {{ /local }}
    >>>>>>>>
    >>>>>>>> This is in the template home-middle.tpl that is the main
    >>>>>>>> column (2nd) for the site layout and the site goes blank on
    >>>>>>>> that area and towards right, left and top loads fine. So I
    >>>>>>>> guess there is some issue of nesting these or maybe because
    >>>>>>>> setting the languages there... I was just happy thinking
    >>>>>>>> understanding the templating and then it didn't work out
    >>>>>>>> again. Well, I'm sure there is a simple way though.
    >>>>>>>>
    >>>>>>>> Gene
    >>>>>>>>
    >>>>>>>> On 17.6.2009, at 13.27, Mugur Rus wrote:
    >>>>>>>>
    >>>>>>>>> Use the language data to decide how do you display the
    >>>>>>>>> articles:
    >>>>>>>>>
    >>>>>>>>> {{ if $campsite->language->code = "en" }}
    >>>>>>>>> {{ assign var="ignore_language" value="true" }}
    >>>>>>>>> {{ else }}
    >>>>>>>>> {{ assign var="ignore_language" value="false" }}
    >>>>>>>>> {{ /if }}
    >>>>>>>>> {{ list_articles ignore_language=`$ignore_language` }}
    >>>>>>>>>
    >>>>>>>>> Hope this helps,
    >>>>>>>>> Mugur
    >>>>>>>>>
    >>>>>>>>> On Mon, Jun 15, 2009 at 10:13 PM, Generare Management
    >>>>>>>>> Department wrote:
    >>>>>>>>> Hi!
    >>>>>>>>>
    >>>>>>>>> Here we are finetuning the content and the huge amount of
    >>>>>>>>> languages.
    >>>>>>>>> Some languages are appearing only with few articles, some
    >>>>>>>>> are more common.
    >>>>>>>>>
    >>>>>>>>> We would like to have the English front page having mixed
    >>>>>>>>> fresh releases of articles.
    >>>>>>>>> It is not a problem to do so or look like we understood how
    >>>>>>>>> to build it but now we get also the same mixed idea if we
    >>>>>>>>> click on other languages front page. How do I restrict the
    >>>>>>>>> mixed, fresh releases to appear only with English and the
    >>>>>>>>> other languages would be pure, only that language
    >>>>>>>>> translations that is selected to as viewed?
    >>>>>>>>>
    >>>>>>>>> I hope you can understand what is the idea.
    >>>>>>>>>
    >>>>>>>>> Gene
    >>>>>>>>>
    >>>>>>>>
    >>>>>>>>
    >>>>>>>>
    >>>>>>>>
    >>>>>>>>
    >>>>>>>
    >>>>>>>
    >>>>>>
    >>>>>>
    >>>
    >>>
  • Thanks!

    I was wondering that I would suggest for our news folks here another
    solution added to this.
    But I first ask you that I won't try something that is not possible:
    would it be handy to make extra language listings in some kind of "if
    sentences" that the content would appear only if there is fresh enough
    articles in that language?

    Like this:

    FIRST the fresh ones in English like they are now.

    THEN other listings below:

    IF there are articles in SWEDISH during last month time (PublishDate
    range?), please show, ELSE, show nothing.
    IF there are articles in FINNISH during last month time, please show,
    ELSE, show nothing.
    IF there are articles in GERMAN during last month time, please show,
    ELSE, show nothing.
    ... ETC.

    This should be possible right? I could choose the main languages
    atleast to give their fresh articles here.

    /Sanna

    On 31.7.2009, at 2.36, Mugur Rus wrote:

    > Hi Sanna,
    >
    > Please copy the templates I attached here over the existing
    > templates. I did some fixes.
    >
    > Please upgrade your campsite install with this version I uploaded
    > here:
    > http://www.campware.org/templates/campsite-3.3.2-rc1.tar.gz
    >
    > The ignore_language option is not useful for what you are trying to
    > achieve so I deleted it from the articles list. Right now it's not
    > possible to display a list of mixed languages, you can only display
    > the latest articles in the same language. We can implement such a
    > feature but can't do it immediately.
    >
    > Mugur
    >
    > On Wed, Jul 29, 2009 at 11:39 PM, Generare Management Department > > wrote:
    > By the way,
    >
    > I have been thinking... when listing articles the variable
    > "ignore_language" could get values "true" and "false" and that's how
    > I got this idea from Mugur with assigning a value for it by another
    > variable, also named "ignore_language". Although used with a $ in
    > the real listing code, can it actually have this reserved name of
    > "ignore_language"?
    >
    > But now when reading the manual again, it doesn't give options for
    > values like "true | false", it says only [ignore_language="true"].
    > So, since even with value "false" the site has been ignoring the
    > language, could that be the reason why my template didn't work? If
    > the ignore_language can be only "true" and not "false", we need to
    > make another solution for the logic of IF English ELSE other
    > languages...
    >
    > list_articles [length=""] [columns=""]
    > [constraints=""]
    > [ignore_issue="true"] [ignore_section="true"]
    > [ignore_language="true"]
    >
    > Thanks for the previous answers as well!
    >
    > /Sanna
    >
    > On 29.7.2009, at 14.55, Generare Management Department wrote:
    >
    >> Yes, I got that Smile
    >>
    >> So we make mix of English and others in English page (just need the
    >> pagination for that)
    >> and
    >> clean languages when getting the other languages pages
    >> (I'm just not getting why it doesn't already work so, but didn't
    >> work with the local test either)
    >>
    >> Sanna
    >>
    >> P.S. Sending you the db pack soon for the general issue
    >>
    >> On 29.7.2009, at 14.35, Mugur Rus wrote:
    >>
    >>> Hi Sanna,
    >>>
    >>> The first option is not doable right now; you can have all English
    >>> articles, but not a mix of English and other languages without
    >>> having also duplicates of the same article in different languages.
    >>>
    >>> Mugur
    >>>
    >>> On Wed, Jul 29, 2009 at 2:04 PM, Generare Management Department >>> > wrote:
    >>> Yes,
    >>>
    >>> we want to display the latest news BUT...
    >>>
    >>> - the default language for the site is ENGLISH and there we want
    >>> to appear all articles that are fresh, no matter which language it
    >>> is (but preference would have been English if it exists and not
    >>> the others)
    >>>
    >>> - when we click a flag (that we have put in the layout) and change
    >>> the language from English to for example Swedish, we want all the
    >>> fresh articles but ONLY in that translation of Swedish
    >>>
    >>> It could be that the explanation is not clear but I could draw an
    >>> example or something...
    >>>
    >>> /Sanna
    >>>
    >>> On 29.7.2009, at 13.56, Mugur Rus wrote:
    >>>
    >>>> The problem here may be some miscommunication; you said you
    >>>> wanted to display the latest news; OK, use list_articles, order
    >>>> them by the publish date and there you have them. But do not use
    >>>> the ignore_language parameter. This, of course, will list all
    >>>> article translations. I remember I said in a previous email, you
    >>>> need to list translations for each article in the list like this:
    >>>>
    >>>> {{ list_articles order="byPublishDate desc" }}
    >>>> display the article in the current language
    >>>> {{ list_languages of_article="true" exclude_current="true" }}
    >>>> display the article translation
    >>>> {{ /list_languages }}
    >>>> {{ /list_articles }}
    >>>>
    >>>> This way you get a list of the latest articles in the current
    >>>> language and their translations. Right now Campsite can't produce
    >>>> a list of articles from different languages and have only one
    >>>> translation of each article in the list.
    >>>>
    >>>> Mugur
    >>>>
    >>>> On Wed, Jul 29, 2009 at 1:40 PM, Generare Management Department >>>> > wrote:
    >>>> Hi!
    >>>>
    >>>> So, to make a short summary:
    >>>>
    >>>>
    >>>>> So now it shows in our English page:
    >>>>> - correctly ignores the language and shows all the recent
    >>>>> articles in any language
    >>>>> - incorrectly shows all the translations of the same article as
    >>>>> recent articles
    >>>>> -> we want to restrict the listing for 1 translation per article
    >>>>> (preferring English if it exists)
    >>>>
    >>>> So, I understood from Mugur's answer on 27th of July that it is
    >>>> not practically possible to restrict the output in a way we want:
    >>>>
    >>>>> Like this in ENGLISH page:
    >>>>>
    >>>>> if there is English -> show only English
    >>>>> if there is other languages -> show in preferred order only the
    >>>>> first one of the list (if Swedish, show that but not for example
    >>>>> the French, or if Finnish show that)
    >>>>
    >>>> CONCLUSION:
    >>>>
    >>>> -> We keep the English giving all the possible article
    >>>> translations of all fresh releases BUT we ADD a pagination.
    >>>> -> For other language we need to restrict to show only those
    >>>> languages that for some reason is not working right now and I do
    >>>> not see anything wrong in the logic that Mugur earlier made for
    >>>> it (template attached)
    >>>>
    >>>> (-> then we need to still figure the troubles of "the advanced
    >>>> search" what is another thread here)
    >>>>
    >>>> We are just very late already with the release of the news site
    >>>> here! Campsite is -imho - very powerful but yet so many obstacles
    >>>> has arised along the way that it was not something we could have
    >>>> foreseen even if we have quite a lot of experience on studying
    >>>> new open source systems. So, very potential system but of course
    >>>> it is never happy to find some bugs or stumble in the lack of
    >>>> knowledge how to do something with a new system.
    >>>>
    >>>> Kind regards,
    >>>>
    >>>> Sanna @ Gene
    >>>>
    >>>>
    >>>>
    >>>>
    >>>> On 28.7.2009, at 23.27, Generare Management Department wrote:
    >>>>
    >>>>> Is the pagination for listing articles something to do with
    >>>>> "currrent list"?
    >>>>> It should have been that English language have "mixed" many
    >>>>> languages but other languages should have only their own article
    >>>>> translations. Now also the other languages get all different
    >>>>> versions of the same article listed.
    >>>>> Need to focus more on what Mugur sent... maybe I changed
    >>>>> something and just can't remember...
    >>>>>
    >>>>> Sanna
    >>>>>
    >>>>> On 27.7.2009, at 23.37, Generare Management Department wrote:
    >>>>>
    >>>>>> Yes,
    >>>>>> I kind of restricted the length for testing purposes to see
    >>>>>> what comes etc.
    >>>>>> The real idea would be anyway to have like 10 newest articles
    >>>>>> on the first page (just boring if they are the same article but
    >>>>>> different translations but we look that later).
    >>>>>> The question is now:
    >>>>>> how do I paginate the articles listing like on the first page
    >>>>>> 10 newest, then 10 next ones, more 10 etc. until certain amount
    >>>>>> of total newest (for example 50 newest altogether).
    >>>>>>
    >>>>>> I was sure there was something like that in the manual but
    >>>>>> can't find it or maybe it was something else...
    >>>>>>
    >>>>>> /Sanna
    >>>>>>
    >>>>>> On 27.7.2009, at 14.03, Mugur Rus wrote:
    >>>>>>
    >>>>>>> You can restrict any list to any length you want: length="1"
    >>>>>>>
    >>>>>>> {{ list_languages of_article="true" exclude_current="true"
    >>>>>>> length="1" }}
    >>>>>>>
    >>>>>>> If you want English to be used whenever possible use:
    >>>>>>> order="byNumber asc"
    >>>>>>>
    >>>>>>> The English language is the first in the table and has the
    >>>>>>> smallest identifier so it will always be the first. Of course,
    >>>>>>> this way is less than ideal to order languages so we can
    >>>>>>> implement in the future a system of language priority for a
    >>>>>>> certain publication.
    >>>>>>>
    >>>>>>> Mugur
    >>>>>>>
    >>>>>>> On Thu, Jul 23, 2009 at 12:57 PM, Generare Management
    >>>>>>> Department wrote:
    >>>>>>> Hi,
    >>>>>>>
    >>>>>>> can I restrict the output of listing for one translation per
    >>>>>>> article?
    >>>>>>> Mugur gave a great idea for the template that we modified for
    >>>>>>> our layout.
    >>>>>>> But the problem is that we still get like 5 different
    >>>>>>> translations of the same article when we would need only one
    >>>>>>> (it's quite boring to list the same article translations and
    >>>>>>> then the list of 10 fits no other articles at all).
    >>>>>>>
    >>>>>>> So now it shows in our English page:
    >>>>>>> - correctly ignores the language and shows all the recent
    >>>>>>> articles in any language
    >>>>>>> - incorrectly shows all the translations of the same article
    >>>>>>> as recent articles
    >>>>>>> -> we want to restrict the listing for 1 translation per
    >>>>>>> article (preferring English if it exists)
    >>>>>>>
    >>>>>>> Like this:
    >>>>>>>
    >>>>>>>> if there is English -> show only English
    >>>>>>>> if there is other languages -> show in preferred order only
    >>>>>>>> the first one of the list (if Swedish, show that but not for
    >>>>>>>> example the French, or if Finnish show that)
    >>>>>>>
    >>>>>>> Sanna @ gene
    >>>>>>>
    >>>>>>> On 23.6.2009, at 15.38, Generare Management Department wrote:
    >>>>>>>
    >>>>>>>> Thanks!
    >>>>>>>>
    >>>>>>>> I tried the template but it messed our layout. No worries, I
    >>>>>>>> combined the good parts and now it works. Smile
    >>>>>>>> Although now it shows of course in English all the possible
    >>>>>>>> translations of the article (I did ask so, no worry), but
    >>>>>>>> could we make in a way that...
    >>>>>>>>
    >>>>>>>> if there is English -> show only English
    >>>>>>>> if there is other languages -> show in preferred order only
    >>>>>>>> the first one of the list (if Swedish, show that but not for
    >>>>>>>> example the French, or if Finnish show that)
    >>>>>>>>
    >>>>>>>> Because when we go to the articles itself, then we have flags
    >>>>>>>> that we can switch the same article in different languages
    >>>>>>>> that is available for it.
    >>>>>>>>
    >>>>>>>> Gene
    >>>>>>>>
    >>>>>>>> On 23.6.2009, at 12.53, Mugur Rus wrote:
    >>>>>>>>
    >>>>>>>>> Please use the attached template; the comparison is made
    >>>>>>>>> using ==, not = so the proper code is:
    >>>>>>>>> {{ if $campsite->language->code == "en" }}
    >>>>>>>>>
    >>>>>>>>> I also made some small optimizations; I removed the local
    >>>>>>>>> statement which is not needed and requires a lot of
    >>>>>>>>> computing resources.
    >>>>>>>>>
    >>>>>>>>> Mugur
    >>>>>>>>>
    >>>>>>>>> On Mon, Jun 22, 2009 at 11:45 PM, Generare Management
    >>>>>>>>> Department wrote:
    >>>>>>>>> Thanks Mugur!
    >>>>>>>>>
    >>>>>>>>> We were making like this based on a sample template:
    >>>>>>>>>
    >>>>>>>>> {{ local }}
    >>>>>>>>> {{ set_current_issue }}
    >>>>>>>>> {{ unset_section }}
    >>>>>>>>> {{ if $campsite->language->code = "en" }}
    >>>>>>>>> {{ assign var="ignore_language" value="true" }}
    >>>>>>>>> {{ else }}
    >>>>>>>>> {{ assign var="ignore_language" value="false" }}
    >>>>>>>>> {{ /if }}
    >>>>>>>>> {{ list_articles length="10" constraints="type is Article
    >>>>>>>>> onsection is on onfrontpage is on"
    >>>>>>>>> ignore_language="$ignore_language" order="bynumber desc" }}
    >>>>>>>>> >>>>>>>>> onmouseover="this.style.backgroundColor='#DCF6D2'"
    >>>>>>>>> style="cursor:pointer;cursor: hand;"
    >>>>>>>>>
    >>>>>>>>> onclick="document.location.href='{{ uri
    >>>>>>>>> options="reset_subtitle_list" }}'"
    >>>>>>>>>
    >>>>>>>>> onmouseout="this.style.backgroundColor='#ffffff'">
    >>>>>>>>>

    {{ $campsite->article->deck }} >>>>>>>>> p>
    >>>>>>>>>

    {{ $campsite->article->name }}


    >>>>>>>>> {{ if $campsite->article->teaser_a != "" }}
    >>>>>>>>>

    {{ $campsite->article-
    >>>>>>>>> >teaser_a }}


    >>>>>>>>> {{ /if }}
    >>>>>>>>> {{ if $campsite->article->teaser_b != "" }}
    >>>>>>>>>

    >>>>>>>>> width="8" height="5">{{ $campsite->article>teaser_a }}


    >>>>>>>>> {{ /if }}
    >>>>>>>>> {{ if $campsite->image->has_image1 }}
    >>>>>>>>>
    >>>>>>>>> border="0">

    >>>>>>>>> {{ /if }}
    >>>>>>>>>

    {{ $campsite->article-
    >>>>>>>>> >intro }}


    >>>>>>>>>
    >>>>>>>>>
    >>>>>>>>> {{ /list_articles }}
    >>>>>>>>> {{ /local }}
    >>>>>>>>>
    >>>>>>>>> This is in the template home-middle.tpl that is the main
    >>>>>>>>> column (2nd) for the site layout and the site goes blank on
    >>>>>>>>> that area and towards right, left and top loads fine. So I
    >>>>>>>>> guess there is some issue of nesting these or maybe because
    >>>>>>>>> setting the languages there... I was just happy thinking
    >>>>>>>>> understanding the templating and then it didn't work out
    >>>>>>>>> again. Well, I'm sure there is a simple way though.
    >>>>>>>>>
    >>>>>>>>> Gene
    >>>>>>>>>
    >>>>>>>>> On 17.6.2009, at 13.27, Mugur Rus wrote:
    >>>>>>>>>
    >>>>>>>>>> Use the language data to decide how do you display the
    >>>>>>>>>> articles:
    >>>>>>>>>>
    >>>>>>>>>> {{ if $campsite->language->code = "en" }}
    >>>>>>>>>> {{ assign var="ignore_language" value="true" }}
    >>>>>>>>>> {{ else }}
    >>>>>>>>>> {{ assign var="ignore_language" value="false" }}
    >>>>>>>>>> {{ /if }}
    >>>>>>>>>> {{ list_articles ignore_language=`$ignore_language` }}
    >>>>>>>>>>
    >>>>>>>>>> Hope this helps,
    >>>>>>>>>> Mugur
    >>>>>>>>>>
    >>>>>>>>>> On Mon, Jun 15, 2009 at 10:13 PM, Generare Management
    >>>>>>>>>> Department wrote:
    >>>>>>>>>> Hi!
    >>>>>>>>>>
    >>>>>>>>>> Here we are finetuning the content and the huge amount of
    >>>>>>>>>> languages.
    >>>>>>>>>> Some languages are appearing only with few articles, some
    >>>>>>>>>> are more common.
    >>>>>>>>>>
    >>>>>>>>>> We would like to have the English front page having mixed
    >>>>>>>>>> fresh releases of articles.
    >>>>>>>>>> It is not a problem to do so or look like we understood how
    >>>>>>>>>> to build it but now we get also the same mixed idea if we
    >>>>>>>>>> click on other languages front page. How do I restrict the
    >>>>>>>>>> mixed, fresh releases to appear only with English and the
    >>>>>>>>>> other languages would be pure, only that language
    >>>>>>>>>> translations that is selected to as viewed?
    >>>>>>>>>>
    >>>>>>>>>> I hope you can understand what is the idea.
    >>>>>>>>>>
    >>>>>>>>>> Gene
    >>>>>>>>>>
    >>>>>>>>>
    >>>>>>>>>
    >>>>>>>>>
    >>>>>>>>>
    >>>>>>>>>
    >>>>>>>>
    >>>>>>>>
    >>>>>>>
    >>>>>>>
    >>>>
    >>>>
    >
    >
    >
    >
    >
    >
  • Hi,

    I was looking with "issue preview" my templates after correcting few
    things based on the templates Mugur gave.
    This report is partially to ask if all is ok and what is wrong with
    the things not working and also for others to learn! Wink

    Preview was giving an parse error like this:

    Parse errors:
    Invalid property intro of object Article


    Reading manual I found this page about Article as object:
    http://code.campware.org/manuals/campsite/3.3/index.php?id=179

    and there a line:
    $campsite->article->content->first_paragraph

    Correcting my template like that gives another error now:

    Parse errors:
    Invalid property content of object Article


    I went ahead removing the above solution. Please comment if there are
    something strange with this template still.
    I took OFF the words after the object "article" and the template is
    following:

    {{ list_search_results order="bypublishdate desc" length="10" }}
    {{ if $campsite->current_list->at_beginning }}

    Found {{ $campsite->current_list->count }} articles
    matching the keyword(s)
    '{{ $campsite->search_articles_action->search_phrase }}'.


    {{ /if }}




    style="cursor:pointer;cursor: hand;"
    onclick="document.location.href='{{ uri options="article" }}'"
    onmouseout="this.style.backgroundColor='#ffffff'" valign="top">

    {{ $campsite->current_list-
    >index }}. {{ $campsite->article->name }}


    {{ $campsite->article }}



    {{ if $campsite->current_list->at_end }}
    {{ local }}
    {{ unset_article }}
    {{ unset_section }}
    {{ if $campsite->current_list->has_previous_elements }}
    search.tpl" }}">Previous
    {{ else }}
    Previous
    {{ /if }}
    |
    {{ if $campsite->current_list->has_next_elements }}
    search.tpl" }}">Next
    {{ else }}
    Next
    {{ /if }}
    {{ /local }}
    {{ /if }}
    {{ /list_search_results }}

    No parse errors anymore and I can get a list of results as well (and
    they seem to be correct atleast when having only a keyword).
    Start and end date calendar is not working (nothing happens when you
    click it). A bug there?

    How do I make a response that NOTHING WAS FOUND in the search?
    Like IF the search results to ZERO article, write "No results. Try
    another word or finetune your search criteria".

    /Sanna
  • Hi Sanna,

    This is entirely possible:
    {{ set_language ... }}
    {{ list_articles constraints="OnFrontPage is on ..." }}
    {{ if $campsite->current_list->at_beginning }}
    display list header (e.g. start table)
    {{ /if }}
    display article
    {{ if $campsite->current_list->at_end }}
    display list footer (e.g. end table)
    {{ /if }}
    {{ /list_articles }}

    This sequence will display articles in the language set at the beginning of
    the sequence. If no articles were found nothing is displayed.

    For simplicity I suggest to put the {{ list_articles }} .. {{ /list_articles
    }} code in a separate template (e.g. list_articles_front_page.tpl) and do it
    like this:

    {{ set_language name="Spanish" }}
    {{ include file="list_articles_front_page.tpl" }}
    {{ set_language name="German" }}
    {{ include file="list_articles_front_page.tpl" }}
    ...
    {{ set_default_language }} - restore the language selected by the reader

    *Please do not forget to do the following:*
    1. Upgrade your campsite install to the version 3.3.2-rc1 because it fixes
    some issues specifically for your site (
    http://www.campware.org/templates/campsite-3.3.2-rc1.tar.gz)
    2. Publish all issue translations, otherwise the translations list won't
    work (Castellano, Dansk etc.). Also, create and publish an issue for Finnish
    language.
    3. I modified home-middle.tpl, line 18: set the length to 25 articles,
    please change it to the value you want.
    4. Translate all topics in all the languages you use, otherwise the advanced
    search form won't show the topics in other languages than English.

    Mugur

    On Fri, Jul 31, 2009 at 10:03 AM, Generare Management Department <
    management@generare.com> wrote:

    > Thanks!
    > I was wondering that I would suggest for our news folks here another
    > solution added to this.
    > But I first ask you that I won't try something that is not possible:
    > would it be handy to make extra language listings in some kind of "if
    > sentences" that the content would appear only if there is fresh enough
    > articles in that language?
    >
    > Like this:
    >
    > FIRST the fresh ones in English like they are now.
    >
    > THEN other listings below:
    >
    > IF there are articles in SWEDISH during last month time (PublishDate
    > range?), please show, ELSE, show nothing.
    > IF there are articles in FINNISH during last month time, please show, ELSE,
    > show nothing.
    > IF there are articles in GERMAN during last month time, please show, ELSE,
    > show nothing.
    > ... ETC.
    >
    > This should be possible right? I could choose the main languages atleast to
    > give their fresh articles here.
    >
    > /Sanna
    >
    > On 31.7.2009, at 2.36, Mugur Rus wrote:
    >
    > Hi Sanna,
    >
    > Please copy the templates I attached here over the existing templates. I
    > did some fixes.
    >
    > Please upgrade your campsite install with this version I uploaded here:
    > http://www.campware.org/templates/campsite-3.3.2-rc1.tar.gz
    >
    > The ignore_language option is not useful for what you are trying to achieve
    > so I deleted it from the articles list. Right now it's not possible to
    > display a list of mixed languages, you can only display the latest articles
    > in the same language. We can implement such a feature but can't do it
    > immediately.
    >
    > Mugur
    >
    > On Wed, Jul 29, 2009 at 11:39 PM, Generare Management Department <
    > management@generare.com> wrote:
    >
    >> By the way,
    >> I have been thinking... when listing articles the variable
    >> "ignore_language" could get values "true" and "false" and that's how I got
    >> this idea from Mugur with assigning a value for it by another variable, also
    >> named "ignore_language". Although used with a $ in the real listing code,
    >> can it actually have this reserved name of "ignore_language"?
    >>
    >> But now when reading the manual again, it doesn't give options for values
    >> like "true | false", it says only [ignore_language="true"]. So, since even
    >> with value "false" the site has been ignoring the language, could that be
    >> the reason why my template didn't work? If the ignore_language can be only
    >> "true" and not "false", we need to make another solution for the logic of IF
    >> English ELSE other languages...
    >>
    >> list_articles [length=""] [columns=""]
    >> [constraints=""]
    >> [ignore_issue="true"] [ignore_section="true"]
    >> [ignore_language="true"]
    >>
    >> Thanks for the previous answers as well!
    >>
    >> /Sanna
    >>
    >> On 29.7.2009, at 14.55, Generare Management Department wrote:
    >>
    >> Yes, I got that Smile
    >> So we make mix of English and others in English page (just need the
    >> pagination for that)
    >> and
    >> clean languages when getting the other languages pages
    >> (I'm just not getting why it doesn't already work so, but didn't work with
    >> the local test either)
    >>
    >> Sanna
    >>
    >> P.S. Sending you the db pack soon for the general issue
    >>
    >> On 29.7.2009, at 14.35, Mugur Rus wrote:
    >>
    >> Hi Sanna,
    >>
    >> The first option is not doable right now; you can have all English
    >> articles, but not a mix of English and other languages without having also
    >> duplicates of the same article in different languages.
    >>
    >> Mugur
    >>
    >> On Wed, Jul 29, 2009 at 2:04 PM, Generare Management Department <
    >> management@generare.com> wrote:
    >>
    >>> Yes,
    >>> we want to display the latest news BUT...
    >>>
    >>> - the default language for the site is ENGLISH and there we want to
    >>> appear all articles that are fresh, no matter which language it is (but
    >>> preference would have been English if it exists and not the others)
    >>>
    >>> - when we click a flag (that we have put in the layout) and change the
    >>> language from English to for example Swedish, we want all the fresh articles
    >>> but ONLY in that translation of Swedish
    >>>
    >>> It could be that the explanation is not clear but I could draw an example
    >>> or something...
    >>>
    >>> /Sanna
    >>>
    >>> On 29.7.2009, at 13.56, Mugur Rus wrote:
    >>>
    >>> The problem here may be some miscommunication; you said you wanted to
    >>> display the latest news; OK, use list_articles, order them by the publish
    >>> date and there you have them. But do not use the ignore_language parameter.
    >>> This, of course, will list all article translations. I remember I said in a
    >>> previous email, you need to list translations for each article in the list
    >>> like this:
    >>>
    >>> {{ list_articles order="byPublishDate desc" }}
    >>> display the article in the current language
    >>> {{ list_languages of_article="true" exclude_current="true" }}
    >>> display the article translation
    >>> {{ /list_languages }}
    >>> {{ /list_articles }}
    >>>
    >>> This way you get a list of the latest articles in the current language
    >>> and their translations. Right now Campsite can't produce a list of articles
    >>> from different languages and have only one translation of each article in
    >>> the list.
    >>>
    >>> Mugur
    >>>
    >>> On Wed, Jul 29, 2009 at 1:40 PM, Generare Management Department <
    >>> management@generare.com> wrote:
    >>>
    >>>> Hi!
    >>>> So, to make a short summary:
    >>>>
    >>>> So now it shows in our English page:
    >>>> - correctly ignores the language and shows all the recent articles in
    >>>> any language
    >>>> - incorrectly shows all the translations of the same article as recent
    >>>> articles
    >>>> -> we want to restrict the listing for 1 translation per article
    >>>> (preferring English if it exists)
    >>>>
    >>>>
    >>>> So, I understood from Mugur's answer on 27th of July that it is not
    >>>> practically possible to restrict the output in a way we want:
    >>>>
    >>>> Like this in ENGLISH page:
    >>>>
    >>>> if there is English -> show only English
    >>>> if there is other languages -> show in preferred order only the first
    >>>> one of the list (if Swedish, show that but not for example the French, or if
    >>>> Finnish show that)
    >>>>
    >>>> *
    >>>> *
    >>>> *CONCLUSION:*
    >>>>
    >>>> *-> We keep the English giving all the possible article translations of
    >>>> all fresh releases BUT we ADD a pagination.*
    >>>> *-> For other language we need to restrict to show only those languages
    >>>> that for some reason is not working right now and I do not see anything
    >>>> wrong in the logic that Mugur earlier made for it (template attached)*
    >>>> *
    >>>> *
    >>>> *(-> then we need to still figure the
    >>>> troubles of "the advanced search" what is another thread here)
    >>>> *
    >>>> We are just very late already with the release of the news site here!
    >>>> Campsite is -imho - very powerful but yet so many obstacles has arised along
    >>>> the way that it was not something we could have foreseen even if we have
    >>>> quite a lot of experience on studying new open source systems. So, very
    >>>> potential system but of course it is never happy to find some bugs or
    >>>> stumble in the lack of knowledge how to do something with a new system.
    >>>>
    >>>> Kind regards,
    >>>>
    >>>> Sanna @ Gene
    >>>>
    >>>>
    >>>>
    >>>>
    >>>> On 28.7.2009, at 23.27, Generare Management Department wrote:
    >>>>
    >>>> Is the pagination for listing articles something to do with "currrent
    >>>> list"? It should have been that English language have "mixed" many
    >>>> languages but other languages should have only their own article
    >>>> translations. Now also the other languages get all different versions of the
    >>>> same article listed.
    >>>> Need to focus more on what Mugur sent... maybe I changed something and
    >>>> just can't remember...
    >>>>
    >>>> Sanna
    >>>>
    >>>> On 27.7.2009, at 23.37, Generare Management Department wrote:
    >>>>
    >>>> Yes, I kind of restricted the length for testing purposes to see what
    >>>> comes etc.
    >>>> The real idea would be anyway to have like 10 newest articles on the
    >>>> first page (just boring if they are the same article but different
    >>>> translations but we look that later).
    >>>> The question is now:
    >>>> how do I paginate the articles listing like on the first page 10 newest,
    >>>> then 10 next ones, more 10 etc. until certain amount of total newest (for
    >>>> example 50 newest altogether).
    >>>>
    >>>> I was sure there was something like that in the manual but can't find it
    >>>> or maybe it was something else...
    >>>>
    >>>> /Sanna
    >>>>
    >>>> On 27.7.2009, at 14.03, Mugur Rus wrote:
    >>>>
    >>>> You can restrict any list to any length you want: length="1"
    >>>>
    >>>> {{ list_languages of_article="true" exclude_current="true" length="1" }}
    >>>>
    >>>> If you want English to be used whenever possible use: order="byNumber
    >>>> asc"
    >>>>
    >>>> The English language is the first in the table and has the smallest
    >>>> identifier so it will always be the first. Of course, this way is less than
    >>>> ideal to order languages so we can implement in the future a system of
    >>>> language priority for a certain publication.
    >>>>
    >>>> Mugur
    >>>>
    >>>> On Thu, Jul 23, 2009 at 12:57 PM, Generare Management Department <
    >>>> management@generare.com> wrote:
    >>>>
    >>>>> Hi,
    >>>>> can I restrict the output of listing for one translation per article?
    >>>>> Mugur gave a great idea for the template that we modified for our
    >>>>> layout.
    >>>>> But the problem is that we still get like 5 different translations of
    >>>>> the same article when we would need only one (it's quite boring to list the
    >>>>> same article translations and then the list of 10 fits no other articles at
    >>>>> all).
    >>>>>
    >>>>> So now it shows in our English page:
    >>>>> - correctly ignores the language and shows all the recent articles in
    >>>>> any language
    >>>>> - incorrectly shows all the translations of the same article as recent
    >>>>> articles
    >>>>> -> we want to restrict the listing for 1 translation per article
    >>>>> (preferring English if it exists)
    >>>>>
    >>>>> Like this:
    >>>>>
    >>>>> if there is English -> show only English
    >>>>> if there is other languages -> show in preferred order only the first
    >>>>> one of the list (if Swedish, show that but not for example the French, or if
    >>>>> Finnish show that)
    >>>>>
    >>>>>
    >>>>> Sanna @ gene
    >>>>>
    >>>>> On 23.6.2009, at 15.38, Generare Management Department wrote:
    >>>>>
    >>>>> Thanks!
    >>>>> I tried the template but it messed our layout. No worries, I combined
    >>>>> the good parts and now it works. Smile
    >>>>> Although now it shows of course in English all the possible
    >>>>> translations of the article (I did ask so, no worry), but could we make in a
    >>>>> way that...
    >>>>>
    >>>>> if there is English -> show only English
    >>>>> if there is other languages -> show in preferred order only the first
    >>>>> one of the list (if Swedish, show that but not for example the French, or if
    >>>>> Finnish show that)
    >>>>>
    >>>>> Because when we go to the articles itself, then we have flags that we
    >>>>> can switch the same article in different languages that is available for it.
    >>>>>
    >>>>> Gene
    >>>>>
    >>>>> On 23.6.2009, at 12.53, Mugur Rus wrote:
    >>>>>
    >>>>> Please use the attached template; the comparison is made using ==, not
    >>>>> = so the proper code is:
    >>>>> {{ if $campsite->language->code == "en" }}
    >>>>>
    >>>>> I also made some small optimizations; I removed the local statement
    >>>>> which is not needed and requires a lot of computing resources.
    >>>>>
    >>>>> Mugur
    >>>>>
    >>>>> On Mon, Jun 22, 2009 at 11:45 PM, Generare Management Department <
    >>>>> management@generare.com> wrote:
    >>>>>
    >>>>>> Thanks Mugur!
    >>>>>> We were making like this based on a sample template:
    >>>>>>
    >>>>>> {{ local }}
    >>>>>> {{ set_current_issue }}
    >>>>>> {{ unset_section }}
    >>>>>> {{ if $campsite->language->code = "en" }}
    >>>>>> {{ assign var="ignore_language" value="true" }}
    >>>>>> {{ else }}
    >>>>>> {{ assign var="ignore_language" value="false" }}
    >>>>>> {{ /if }}
    >>>>>> {{ list_articles length="10" constraints="type is Article onsection is
    >>>>>> on onfrontpage is on" ignore_language="$ignore_language" order="bynumber
    >>>>>> desc" }}
    >>>>>> >>>>>> onmouseover="this.style.backgroundColor='#DCF6D2'"
    >>>>>> style="cursor:pointer;cursor: hand;"
    >>>>>> onclick="document.location.href='{{ uri
    >>>>>> options="reset_subtitle_list" }}'"
    >>>>>>
    >>>>>> onmouseout="this.style.backgroundColor='#ffffff'">
    >>>>>>

    {{ $campsite->article->deck }}


    >>>>>>

    {{ $campsite->article->name }}


    >>>>>> {{ if $campsite->article->teaser_a != "" }}
    >>>>>>

    {{ $campsite->article->teaser_a }}


    >>>>>> {{ /if }}
    >>>>>> {{ if $campsite->article->teaser_b != "" }}
    >>>>>>

    >>>>>> height="5">{{ $campsite->article>teaser_a }}


    >>>>>> {{ /if }}
    >>>>>> {{ if $campsite->image->has_image1 }}
    >>>>>>
    >>>>>> src="/get_img.php?{{ urlparameters options="image 1" }}" border="0">

    >>>>>> {{ /if }}
    >>>>>>

    {{ $campsite->article->intro
    >>>>>> }}


    >>>>>>
    >>>>>>
    >>>>>> {{ /list_articles }}
    >>>>>> {{ /local }}
    >>>>>>
    >>>>>> This is in the template home-middle.tpl that is the main column (2nd)
    >>>>>> for the site layout and the site goes blank on that area and towards right,
    >>>>>> left and top loads fine. So I guess there is some issue of nesting these or
    >>>>>> maybe because setting the languages there... I was just happy thinking
    >>>>>> understanding the templating and then it didn't work out again. Well, I'm
    >>>>>> sure there is a simple way though.
    >>>>>>
    >>>>>> Gene
    >>>>>>
    >>>>>> On 17.6.2009, at 13.27, Mugur Rus wrote:
    >>>>>>
    >>>>>> Use the language data to decide how do you display the articles:
    >>>>>>
    >>>>>> {{ if $campsite->language->code = "en" }}
    >>>>>> {{ assign var="ignore_language" value="true" }}
    >>>>>> {{ else }}
    >>>>>> {{ assign var="ignore_language" value="false" }}
    >>>>>> {{ /if }}
    >>>>>> {{ list_articles ignore_language=`$ignore_language` }}
    >>>>>>
    >>>>>> Hope this helps,
    >>>>>> Mugur
    >>>>>>
    >>>>>> On Mon, Jun 15, 2009 at 10:13 PM, Generare Management Department <
    >>>>>> management@generare.com> wrote:
    >>>>>>
    >>>>>>> Hi!
    >>>>>>>
    >>>>>>> Here we are finetuning the content and the huge amount of languages.
    >>>>>>> Some languages are appearing only with few articles, some are more
    >>>>>>> common.
    >>>>>>>
    >>>>>>> We would like to have the English front page having mixed fresh
    >>>>>>> releases of articles.
    >>>>>>> It is not a problem to do so or look like we understood how to build
    >>>>>>> it but now we get also the same mixed idea if we click on other languages
    >>>>>>> front page. How do I restrict the mixed, fresh releases to appear only with
    >>>>>>> English and the other languages would be pure, only that language
    >>>>>>> translations that is selected to as viewed?
    >>>>>>>
    >>>>>>> I hope you can understand what is the idea.
    >>>>>>>
    >>>>>>> Gene
    >>>>>>>
    >>>>>>
    >>>>>>
    >>>>>>
    >>>>>>
    >>>>>
    >>>>>
    >>>>>
    >>>>>
    >>>>>
    >>>>
    >>
    >>
    >>
    >
    >
    >
    >
    >
    >
  • Hi Sanna,

    Don't worry about the parse errors of this kind: "Invalid property
    *intro*of object Article". I noticed in your templates statements like
    this:
    {{ $campsite->article->intro }}
    in places where an article is not ever defined: outside lists of articles,
    on the front page. In these cases you'll get these errors but they do not
    affect the site behavior. You can delete these statements.

    When displaying an article content you have to know the structure of your
    article type. Almost all of your articles are of type "Article" which has
    the following structure:

    - Deck - single line text (hidden)
    - Byline - single line text (hidden)
    - Teaser_a - single line text
    - Teaser_b - single line text
    - Intro - multiline text
    - Full_text - multiline text

    So in order to display your article content you have to insert the following
    statement:
    {{ $campsite->article->Full_text }}

    Then you can also write:
    {{ $campsite->article->Full_text->first_paragraph }} which will cut the text
    to the first paragraph.

    The statement {{ $campsite->article }} does not display anything;
    $campsite->article is an object with properties and you can display any of
    these properties.

    Please replace this line in your template:

    {{ $campsite->article }}


    with:

    {{ $campsite->article->Full_text }}



    I notice you didn't use the fields "Deck", "Byline", "Teaser_a" and
    "Teaser_b" and "Intro" so you can remove them from the article type edit
    screen (admin menu: Configure->Article Types->Fields)

    Regarding "Nothing was found", paste the following code after your search
    results list:
    {{ if $campsite->prev_list_empty }}

    No results. Try another word or fine tune your search criteria.


    {{ /if }}

    Regarding the start and end dates I'll check your templates locally and get
    back to you.

    Mugur

    On Fri, Jul 31, 2009 at 11:12 AM, Generare Management Department <
    management@generare.com> wrote:

    > Hi,
    > I was looking with "issue preview" my templates after correcting few things
    > based on the templates Mugur gave.
    > This report is partially to ask if all is ok and what is wrong with the
    > things not working and also for others to learn! Wink
    >
    > Preview was giving an parse error like this:
    >
    > Parse errors:
    > Invalid property *intro* of object Article
    >
    >
    >
    > Reading manual I found this page about Article as object:
    > http://code.campware.org/manuals/campsite/3.3/index.php?id=179
    >
    > and there a line:
    > $campsite->article->content->first_paragraph
    >
    > Correcting my template like that gives another error now:
    >
    > Parse errors:
    > Invalid property *content* of object Article
    >
    >
    >
    > I went ahead removing the above solution. Please comment if there are
    > something strange with this template still.I took OFF the words after the
    > object "article" and the template is following:
    > {{ list_search_results order="bypublishdate desc" length="10" }}
    > {{ if $campsite->current_list->at_beginning }}
    >

    Found {{ $campsite->current_list->count }} articles matching the
    > keyword(s)
    > '{{ $campsite->search_articles_action->search_phrase }}'.


    > {{ /if }}
    >
    >
    >
    >
    >
    > style="cursor:pointer;cursor: hand;" onclick="document.location.href='{{ uri
    > options="article" }}'" onmouseout="this.style.backgroundColor='#ffffff'"
    > valign="top">
    >

    {{ $campsite->current_list->index }}.
    > {{ $campsite->article->name }}


    >

    {{ $campsite->article }}


    >

    > {{ if $campsite->current_list->at_end }}
    > {{ local }}
    > {{ unset_article }}
    > {{ unset_section }}
    > {{ if $campsite->current_list->has_previous_elements }}
    > > }}">Previous
    > {{ else }}
    > Previous
    > {{ /if }}
    > |
    > {{ if $campsite->current_list->has_next_elements }}
    > > }}">Next
    > {{ else }}
    > Next
    > {{ /if }}
    > {{ /local }}
    > {{ /if }}
    > {{ /list_search_results }}
    >
    > No parse errors anymore and I can get a list of results as well (and they
    > seem to be correct atleast when having only a keyword).
    > Start and end date calendar is not working (nothing happens when you click
    > it). A bug there?
    >
    > How do I make a response that NOTHING WAS FOUND in the search?
    > Like IF the search results to ZERO article, write "No results. Try another
    > word or finetune your search criteria".
    >
    > /Sanna
    >
    >
  • Hi,

    thanks for the previous advices.

    In our search form there are sections to be picked but they are not in
    alphabetical order in the administration (rather in the order of
    creation of course) but it would be useful to get it so in the search
    form.

    Our attempt was to add order conditions here:

    Section: {{ camp_select object="search" attribute="section" }}



    like this:

    Section: {{ camp_select object="search" attribute="section"
    order="byName desc" }}



    I didn't find anything from the manual concerning this.
    Anyhow we may have hundreds of sections and having them in another
    than alphabetical order in the search form is not very practical.

    /Sanna


    On 1.8.2009, at 20.19, Mugur Rus wrote:

    > Regarding "Nothing was found", paste the following code after your
    > search results list:
    > {{ if $campsite->prev_list_empty }}
    >

    No results. Try another word or fine tune your search
    > criteria.


    > {{ /if }}
    >
    > Regarding the start and end dates I'll check your templates locally
    > and get back to you.
  • It has also the fixes from 28th of July in this file? (this is the
    exact same php file that was fixed then for another issue that caused
    blank site)

    Just asking that we keep the track of everything...

    /Sanna

    On 4.8.2009, at 14.44, Mugur Rus wrote:

    > Please copy the attached file (function.camp_select.php) to the
    > directory [campsite_dir]/smarty_camp_plugins. This will fix your
    > problem. I'll also commit this change so all new versions will keep
    > this behavior.
    >
    > Mugur
    >
    > On Tue, Aug 4, 2009 at 10:05 AM, Generare Management Department > > wrote:
    > Hi,
    >
    > thanks for the previous advices.
    >
    > In our search form there are sections to be picked but they are not
    > in alphabetical order in the administration (rather in the order of
    > creation of course) but it would be useful to get it so in the
    > search form.
    >
    > Our attempt was to add order conditions here:
    >
    >

    Section: {{ camp_select object="search" attribute="section" }}


    >
    > like this:
    >
    >

    Section: {{ camp_select object="search" attribute="section"
    > order="byName desc" }}


    >
    > I didn't find anything from the manual concerning this.
    > Anyhow we may have hundreds of sections and having them in another
    > than alphabetical order in the search form is not very practical.
    >
    > /Sanna
    >
    >
    >
    > On 1.8.2009, at 20.19, Mugur Rus wrote:
    >
    > Regarding "Nothing was found", paste the following code after your
    > search results list:
    > {{ if $campsite->prev_list_empty }}
    >

    No results. Try another word or fine tune your search
    > criteria.


    > {{ /if }}
    >
    > Regarding the start and end dates I'll check your templates locally
    > and get back to you.
    >
    >
    >
    >
    >
    >
    >
  • Yes, whatever I send you are the latest versions that include everything
    that was fixed until then.

    Mugur

    On Tue, Aug 4, 2009 at 2:49 PM, Generare Management Department <
    management@generare.com> wrote:

    > It has also the fixes from 28th of July in this file? (this is the exact
    > same php file that was fixed then for another issue that caused blank site)
    > Just asking that we keep the track of everything...
    >
    > /Sanna
    >
    > On 4.8.2009, at 14.44, Mugur Rus wrote:
    >
    > Please copy the attached file (function.camp_select.php) to the directory
    > [campsite_dir]/smarty_camp_plugins. This will fix your problem. I'll also
    > commit this change so all new versions will keep this behavior.
    >
    > Mugur
    >
    > On Tue, Aug 4, 2009 at 10:05 AM, Generare Management Department <
    > management@generare.com> wrote:
    >
    >> Hi,
    >>
    >> thanks for the previous advices.
    >>
    >> In our search form there are sections to be picked but they are not in
    >> alphabetical order in the administration (rather in the order of creation of
    >> course) but it would be useful to get it so in the search form.
    >>
    >> Our attempt was to add order conditions here:
    >>
    >>

    Section: {{ camp_select object="search" attribute="section" }}


    >>
    >> like this:
    >>
    >>

    Section: {{ camp_select object="search" attribute="section"
    >> order="byName desc" }}


    >>
    >> I didn't find anything from the manual concerning this.
    >> Anyhow we may have hundreds of sections and having them in another than
    >> alphabetical order in the search form is not very practical.
    >>
    >> /Sanna
    >>
    >>
    >>
    >> On 1.8.2009, at 20.19, Mugur Rus wrote:
    >>
    >> Regarding "Nothing was found", paste the following code after your search
    >>> results list:
    >>> {{ if $campsite->prev_list_empty }}
    >>>

    No results. Try another word or fine tune your search criteria.


    >>> {{ /if }}
    >>>
    >>> Regarding the start and end dates I'll check your templates locally and
    >>> get back to you.
    >>>
    >>
    >>
    >>
    >>
    >>
    >>
    >
    >
    >
    >
    >
    >
    >
  • Great,
    it could be great to have this same in the administration (could be
    put into the list of "features wished").
    When you go to section lists you can see - like in our case 845
    sections - but it is hard work to find the right section when they are
    not in the alphabetical order but in the order of the creation.

    It could be in a way that you click the title "Name" in the section
    list and it turns all in alphabetical order.

    But no stress for the above, just an idea to make it more practical.

    Have you had time to look the start and end dates functionality for
    the search? Any updates on that?
    By the way, does the search function always need a keyword? Or can I
    search only by restricting to topics and sections? Atleast I do not
    get any results if I do not have a keyword. (Since in our case each
    section is a different company and its articles, it would be useful to
    pick up the articles per section / company like this)

    ABOUT RESULT TEXT:

    Found 1 articles matching the keyword(s) 'm
  • Hi Sanna,

    It is not a bug but the way it works, from the manual
    (http://code.campware.org/manuals/campsite/3.3/index.php?id7):

    "search_keywords: an array of keywords for which the search was performed"

    Cheers,


    On Tue, Aug 4, 2009 at 7:14 AM, Generare Management
    Department wrote:
    > Great,
    > it could be great to have this same in the administration (could be put into
    > the list of "features wished").
    > When you go to section lists you can see
  • Here is the proper code to display the section and topic of the search if
    they were defined:

    {{ if $campsite->current_list->at_beginning }}

    Found {{
    $campsite->current_list->count }} articles matching the keyword(s)
    '{{ $campsite->search_articles_action->search_phrase }}'
    {{ if $campsite->search_articles_action->search_section > 0 }}
    from section {{ $campsite->article->section->name }}
    {{ /if }}
    {{ if $campsite->search_articles_action->topic_id > 0 }}
    {{ local }}
    {{ set_topic
    identifier=`$campsite->search_articles_action->topic_id` }}
    having the topic {{ $campsite->topic->name }}
    {{ /local }}
    {{ /if }}


    {{ /if }}

    The search does not return any result if you didn't input at least a
    keyword. I'm checking the start date/end date fields...

    Mugur

    On Tue, Aug 4, 2009 at 3:14 PM, Generare Management Department <
    management@generare.com> wrote:

    > Great,it could be great to have this same in the administration (could be
    > put into the list of "features wished").
    > When you go to section lists you can see - like in our case 845 sections -
    > but it is hard work to find the right section when they are not in the
    > alphabetical order but in the order of the creation.
    >
    > It could be in a way that you click the title "Name" in the section list
    > and it turns all in alphabetical order.
    >
    > But no stress for the above, just an idea to make it more practical.
    >
    > Have you had time to look the start and end dates functionality for the
    > search? Any updates on that?
    > By the way, does the search function always need a keyword? Or can I search
    > only by restricting to topics and sections? Atleast I do not get any results
    > if I do not have a keyword. (Since in our case each section is a different
    > company and its articles, it would be useful to pick up the articles per
    > section / company like this)
    >
    > ABOUT RESULT TEXT:
    >
    > *Found 1 articles matching the keyword(s) 'mänskliga' 'Array'.*
    >
    > Our code in the template is like this:
    >
    > {{ if $campsite->current_list->at_beginning }}
    >

    Found {{ $campsite->current_list->count }} articles matching the
    > keyword(s)
    > '{{ $campsite->search_articles_action->search_phrase }}'
    > '{{ $campsite->search_articles_action->search_keywords }}'.


    > {{ /if }}
    >
    > I would like that it would say from which section or topic was the result
    > (if they were used) but now it says "Array" only. A bug? Or mistake in the
    > template or both?
    >
    > No worry, as soon as I get this site in better shape, I'll start
    > contributing some example code for your manual.
    > We will save some trouble when new "beginners" come to use Campsite... Wink
    >
    > Sanna @ Gene
    >
    > On 4.8.2009, at 14.51, Mugur Rus wrote:
    >
    > Yes, whatever I send you are the latest versions that include everything
    > that was fixed until then.
    >
    > Mugur
    >
    > On Tue, Aug 4, 2009 at 2:49 PM, Generare Management Department <
    > management@generare.com> wrote:
    >
    >> It has also the fixes from 28th of July in this file? (this is the exact
    >> same php file that was fixed then for another issue that caused blank site)
    >> Just asking that we keep the track of everything...
    >>
    >> /Sanna
    >>
    >> On 4.8.2009, at 14.44, Mugur Rus wrote:
    >>
    >> Please copy the attached file (function.camp_select.php) to the directory
    >> [campsite_dir]/smarty_camp_plugins. This will fix your problem. I'll also
    >> commit this change so all new versions will keep this behavior.
    >>
    >> Mugur
    >>
    >> On Tue, Aug 4, 2009 at 10:05 AM, Generare Management Department <
    >> management@generare.com> wrote:
    >>
    >>> Hi,
    >>>
    >>> thanks for the previous advices.
    >>>
    >>> In our search form there are sections to be picked but they are not in
    >>> alphabetical order in the administration (rather in the order of creation of
    >>> course) but it would be useful to get it so in the search form.
    >>>
    >>> Our attempt was to add order conditions here:
    >>>
    >>>

    Section: {{ camp_select object="search" attribute="section" }}


    >>>
    >>> like this:
    >>>
    >>>

    Section: {{ camp_select object="search" attribute="section"
    >>> order="byName desc" }}


    >>>
    >>> I didn't find anything from the manual concerning this.
    >>> Anyhow we may have hundreds of sections and having them in another than
    >>> alphabetical order in the search form is not very practical.
    >>>
    >>> /Sanna
    >>>
    >>>
    >>>
    >>> On 1.8.2009, at 20.19, Mugur Rus wrote:
    >>>
    >>> Regarding "Nothing was found", paste the following code after your
    >>>> search results list:
    >>>> {{ if $campsite->prev_list_empty }}
    >>>>

    No results. Try another word or fine tune your search
    >>>> criteria.


    >>>> {{ /if }}
    >>>>
    >>>> Regarding the start and end dates I'll check your templates locally and
    >>>> get back to you.
    >>>>
    >>>
    >>>
    >>>
    >>>
    >>>
    >>>
    >>
    >>
    >>
    >>
    >>
    >
    >
    >
    >
  • Please duplicate the file calendar-en.js to calendar-en_US.js in the
    directory [campsite_dir]/javascript/jscalendar/lang. Do the same thing for
    all languages for which you changed the code. This will fix your search form
    start/end date problem.

    Mugur

    On Tue, Aug 4, 2009 at 3:14 PM, Generare Management Department <
    management@generare.com> wrote:

    > Great,it could be great to have this same in the administration (could be
    > put into the list of "features wished").
    > When you go to section lists you can see - like in our case 845 sections -
    > but it is hard work to find the right section when they are not in the
    > alphabetical order but in the order of the creation.
    >
    > It could be in a way that you click the title "Name" in the section list
    > and it turns all in alphabetical order.
    >
    > But no stress for the above, just an idea to make it more practical.
    >
    > Have you had time to look the start and end dates functionality for the
    > search? Any updates on that?
    > By the way, does the search function always need a keyword? Or can I search
    > only by restricting to topics and sections? Atleast I do not get any results
    > if I do not have a keyword. (Since in our case each section is a different
    > company and its articles, it would be useful to pick up the articles per
    > section / company like this)
    >
    > ABOUT RESULT TEXT:
    >
    > *Found 1 articles matching the keyword(s) 'mänskliga' 'Array'.*
    >
    > Our code in the template is like this:
    >
    > {{ if $campsite->current_list->at_beginning }}
    >

    Found {{ $campsite->current_list->count }} articles matching the
    > keyword(s)
    > '{{ $campsite->search_articles_action->search_phrase }}'
    > '{{ $campsite->search_articles_action->search_keywords }}'.


    > {{ /if }}
    >
    > I would like that it would say from which section or topic was the result
    > (if they were used) but now it says "Array" only. A bug? Or mistake in the
    > template or both?
    >
    > No worry, as soon as I get this site in better shape, I'll start
    > contributing some example code for your manual.
    > We will save some trouble when new "beginners" come to use Campsite... Wink
    >
    > Sanna @ Gene
    >
    > On 4.8.2009, at 14.51, Mugur Rus wrote:
    >
    > Yes, whatever I send you are the latest versions that include everything
    > that was fixed until then.
    >
    > Mugur
    >
    > On Tue, Aug 4, 2009 at 2:49 PM, Generare Management Department <
    > management@generare.com> wrote:
    >
    >> It has also the fixes from 28th of July in this file? (this is the exact
    >> same php file that was fixed then for another issue that caused blank site)
    >> Just asking that we keep the track of everything...
    >>
    >> /Sanna
    >>
    >> On 4.8.2009, at 14.44, Mugur Rus wrote:
    >>
    >> Please copy the attached file (function.camp_select.php) to the directory
    >> [campsite_dir]/smarty_camp_plugins. This will fix your problem. I'll also
    >> commit this change so all new versions will keep this behavior.
    >>
    >> Mugur
    >>
    >> On Tue, Aug 4, 2009 at 10:05 AM, Generare Management Department <
    >> management@generare.com> wrote:
    >>
    >>> Hi,
    >>>
    >>> thanks for the previous advices.
    >>>
    >>> In our search form there are sections to be picked but they are not in
    >>> alphabetical order in the administration (rather in the order of creation of
    >>> course) but it would be useful to get it so in the search form.
    >>>
    >>> Our attempt was to add order conditions here:
    >>>
    >>>

    Section: {{ camp_select object="search" attribute="section" }}


    >>>
    >>> like this:
    >>>
    >>>

    Section: {{ camp_select object="search" attribute="section"
    >>> order="byName desc" }}


    >>>
    >>> I didn't find anything from the manual concerning this.
    >>> Anyhow we may have hundreds of sections and having them in another than
    >>> alphabetical order in the search form is not very practical.
    >>>
    >>> /Sanna
    >>>
    >>>
    >>>
    >>> On 1.8.2009, at 20.19, Mugur Rus wrote:
    >>>
    >>> Regarding "Nothing was found", paste the following code after your
    >>>> search results list:
    >>>> {{ if $campsite->prev_list_empty }}
    >>>>

    No results. Try another word or fine tune your search
    >>>> criteria.


    >>>> {{ /if }}
    >>>>
    >>>> Regarding the start and end dates I'll check your templates locally and
    >>>> get back to you.
    >>>>
    >>>
    >>>
    >>>
    >>>
    >>>
    >>>
    >>
    >>
    >>
    >>
    >>
    >
    >
    >
    >